Coder Social home page Coder Social logo

puppet-gitlab's Introduction

DEPRECATED

##Use the vshn/puppet-gitlab module instead

Why

This module was written back befefore omnibus when you had to compile from source. Revision 2.0 of the puppet module used the omnibus, but it downloaded packages from aws in a fragile way. With the advent of cloudpackages, it was time to rewrite again to use the repos. vshn beat me to it and wrote an excellent puppet module exactly how I would have refactored this one. Rather that duplicate his work, I'm passing the torch to him.

puppet-gitlab's People

Contributors

andrekeller avatar b4ldr avatar daniellawrence avatar davids avatar dblessing avatar edestecd avatar hjjacobs avatar iandennismiller avatar igalic avatar janbraiins avatar jasperla avatar minoroffense avatar patrickpl avatar rickard-von-essen avatar spidersddd avatar spuder avatar tdb avatar timhughes avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

puppet-gitlab's Issues

Setup SSL

This needs variables for ssl certificates, and testing of the nginx ssl config

Module doesn't automatically install mysql

Make sure installing spuder-gitlab automatically installs puppet labs mysql

Chat transcript from puppet irc

Hefeweizen: I'm attempting https://forge.puppetlabs.com/spuder/gitlab. initialized the database successfully, but trying gitlab, I get: Error: Could not find dependency Class[Mysql::Server] for Mysql_grant[gitlabdbu@localhost/gitlabdb.*] at /etc/puppet/modules/mysql/manifests/db.pp:44
[2:26pm] rlinehan left the chat room. (Remote host closed the connection)
[2:27pm] shellox left the chat room. (Ping timeout: 240 seconds)
[2:27pm] spuder: Hefeweizen The puppet module 'should' automatically download puppetlabs-mysql 2.0.0. If it doesn't, you'll need to manually install the module 'puppet module install puppetlabs-mysql'
[2:28pm] torrancew: Hefeweizen: how did you install spuder/gitlab?
[2:28pm] spuder: I'll open a github issue to look at that
[2:28pm] themurph left the chat room. (Remote host closed the connection)
[2:28pm] Hefeweizen: heh. Sorry, wasn't expecting to get the answer from the author.
[2:28pm] torrancew: That happens in here sometimes
[2:28pm] walterheck joined the chat room.
[2:28pm] torrancew: Since pasting a url from someone's repo will generally highlight them if IRC+Github names are the same

https://gist.github.com/Hefeweizen/6fdc874f51ce8da1e9de

Remove Ruby rep

Don't install ruby2.0 manually, instead use the puppet ruby module, gitlab shouldn't use ruby 2.0 either

installation failure

Hi

I am trying to use the module, and when I run
puppet apply --verbose /etc/puppet/manifests/sites.pp

I get

Failed to parse template gitlab/nginx-gitlab.conf.erb:
  Filepath: /usr/lib/ruby/vendor_ruby/puppet/parser/scope.rb
  Line: 459
  Detail: undefined method `[]' for #<Puppet::Parser::Scope:0x7fdd51225660>
 at /etc/puppet/modules/gitlab/manifests/config.pp:92 on node gitlab05.xx.xx

The gitlab section of sites.pp looks like this (if is mostly copied from the example)

  class { 'gitlab' : 
    git_email              =>  '[email protected]',
    gitlab_branch          =>  '6-7-stable',
    gitlab_dbname          =>  $gitlab_dbname,
    gitlab_dbuser          =>  $gitlab_dbuser,
    gitlab_dbpwd           =>  $gitlab_dbpwd,
    gitlab_projects        =>  '15',
    user_changename        =>  true,
}

I have installed nginx manually, and it is accesible on port 80.

I am not sure what to make of the error and how to debug it. Suggestions are welcome.

regards
moz

Debian not supported

When tries install at a debian wheezy, got this error.

" Error: Could not retrieve catalog from remote server: Error 400 on SERVER: apt::ppa is currently supported on Ubuntu only. at /etc/puppet/modules/apt/manifests/ppa.pp:18 on node linguado.mydomain "

Its clearly a apt::ppa problem, but the module description says that will work fine in Debian systems.

Remove rake checks

the puppet run saves the output of the rake tests to a hidden file in the home directory,

no one uses this, and it causes the install to take an extra minute or two.

comment it ou

Readme Syntax Errors

The Readme Page has some mistakes.

The explained class parameter examples are with
$parameter = value,
instead of
parameter => value,

Additionally it would be helpful when the First Login credentials are in the Readme.
I found them on the sbadia/puppet-gitlab Project Readme

Create fail cases

init.pp

Add fail() for following conditions
puppet < 3.2
puppetlabs-mysql < 2.0.0

Fix 6-1 gitlab.yml

the 6-1 gitlab.yml document has a whole bunch of errors (see how ldap has no variables)? 6-1 shouldn't even work at all.

Fix indentation

Indents look correct in geppetto, but not online, or in vim

Add unicorn config options

Add flags that allow you to configure the following settings in the unicorn.rb

worker_processes 2
timeout 30 (I think I already enabled this in 1.3.0, but double check)

Ruby is reinstalled every puppet run

Affects version 1.7.0

This happens every puppet run. Stop it, stop it now.

notice ensure changed 'purged' to 'present' /Stage[main]/Ruby/Package[rubygems]/ensure

Ruby version is too tightly coupled with ruby 1.9.x

Gitlab suggests running ruby 2.0

Unfortunately the highest package level available to ubuntu 12.04 is ruby 1.9.3.

Either bundle ruby 2.0 with the gitlab module, or remove the code that installs ruby 1.9 and allow the user to install ruby themselves (kind of like what was done with mysql in tests/init.pp)

This shouldn't be a problem once ubuntu 14.04 is out.

broken mysql module dependency

Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Invalid relationship: Mysql_database[gitlabdb] { require => Class[Mysql::Server] }, because Class[Mysql::Server] doesn't seem to be in the catalog
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run

Remove /home/git variable

users shouldn't be able to change the git home variable because it will break stuff, this should be removed.

Use default init script

I have modified the init script to exit with code 3,

revert to the origional init script, but change the status command to ps aux

Database permissions

Change database from all to just the minimum required in the install doc
Packages.pp

Replacing icons is not allowed

If you try and replace the grumpy kitty icons after they have already been placed, you get the following error

Notice: /Stage[main]/Gitlab::Config/File[/home/git/gitlab/app/assets/images/company-logo-white.png]/content:
Binary files /home/git/gitlab/app/assets/images/company-logo-white.png and /tmp/puppet-file20131010-8902-46j9ez differ

Error: Could not back up /home/git/gitlab/app/assets/images/company-logo-white.png: Error 400 on SERVER: Got passed new contents for sum {md5}bfc65ed7d76ba85e165230a8db9100aa
Error: Could not back up /home/git/gitlab/app/assets/images/company-logo-white.png: Error 400 on SERVER: Got passed new contents for sum {md5}bfc65ed7d76ba85e165230a8db9100aa
Error: /Stage[main]/Gitlab::Config/File[/home/git/gitlab/app/assets/images/company-logo-white.png]/content: change from {md5}bfc65ed7d76ba85e165230a8db9100aa to {md5}60a35ec44fa591ef0d67459fae9fa0af failed: Could not back up /home/git/gitlab/app/assets/images/company-logo-white.png: Error 400 on SERVER: Got passed new contents for sum {md5}bfc65ed7d76ba85e165230a8db9100aa
Notice: /Stage[main]/Gitlab::Config/Exec[git config --global user.name]/returns: executed successfully

Find a work around to make it so that puppet doesn't try and back them up

Support for RedHat

Currently after configuring everything to start up on a non-Debian system it complains that it's not supported yet, including RedHat. Generally the goal of Puppet is to abstract away from the system tools. If using the more generic Puppet accessors (such as "package {}" and such) are undesirable then this module really needs to have Debian as a listed REQUIREMENT, not just a tested system.

mysql permissions are changed every puppet run

Mysql updates the tables every puppet run. Please don't do that, it makes me sad.

/etc/puppet/modules/ruby/manifests/init.pp  96  2014-02-27 10:18 MST
notice  privileges changed ['SELECT', 'INSERT', 'UPDATE', 'DELETE', 'CREATE', 'DROP', 'INDEX', 'ALTER', 'LOCK TABLES'] to 'SELECT LOCK TABLES INSERT UPDATE DELETE CREATE DROP INDEX ALTER' /Stage[main]/Gitlab::Packages/Mysql::Db[gitlabdb]/Mysql_grant[gitlabdbu@localhost/gitlabdb.*]/privileges    /etc/puppet/modules/mysql/manifests/db.pp   44  2014-02-27 10:19 MST
notice  Finished catalog run in 10.50 seconds   Puppet          2014-02-27 10:19 MST

Restrict database to just the necessary permissions

Pre-2.0 syntax (notice it uses grant => 'all'
#mysql::db { "$gitlab::params::gitlab_dbname" :
# ensure => present,
# user => "$gitlab::params::gitlab_dbuser",
# password => "$gitlab::params::gitlab_dbpwd",
# host => "$gitlab::params::gitlab_dbhost",
# grant => ['all'],
# #TODO: change from all, to just the permissions specififed in the install doc
#}

Module has dependency cycle

Debug: /Stage[main]/Mysql::Server::Config/File[/etc/mysql/my.cnf]: Autorequiring File[/etc/mysql]
Info: Applying configuration version '1383610017'
Error: Could not apply complete catalog: Found 1 dependency cycle:
(Exec[download gitlab-shell] => Class[Gitlab::Setup] => Class[Gitlab::Install] => Exec[setup gitlab database] => Class[Gitlab::Install] => Class[Gitlab::Config] => File[/home/git] => Exec[download gitlab-shell])
Cycle graph written to /var/lib/puppet/state/graphs/cycles.dot.
Debug: Storing state

By running with --graph, puppet generated the following diagram

graphviz

Remove teams

$user_create_team is no longer valid as of 6.0 according to the irc channel, deprecate it

module doesn't depend on postfix

The class declares a dependency on postfix, but it is never used.

Either add a dependency to the manifests file, or rip postfix from the module completely.

Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Could not find class postfix for puppet-gitlab.novalocal on node puppet-gitlab.novalocal
Warning: Not using cache on failed catalog
Error: Could not retrieve catalog; skipping run

nginx use multiple domains

right now the nginx only does a 301 redirect if using the hostname,

change this to a wild card so you can use any domain and be redirected to https

for example, all of these should redirect to the fqdn

gitlab.microsoft.com
gitlab.ms.com
gitlab.ms
192.168.33.10

Set gitlab-shell permissions

root@gitlab:/home/git/gitlab-shell# sudo -u git -H ./bin/install
mkdir -p /home/git/repositories: true
mkdir -p /home/git/.ssh: true
chmod 700 /home/git/.ssh: true
touch /home/git/.ssh/authorized_keys: true
chmod 600 /home/git/.ssh/authorized_keys: true
chmod -R ug+rwX,o-rwx /home/git/repositories: true
find /home/git/repositories -type d -print0 | xargs -0 chmod g+s: true

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.