Git Product home page Git Product logo

ansible-gitlab's Introduction

DebOps logo DebOps

Your Debian-based data center in a box

GitHub CI GitLab CI CII Best Practices REUSE status RSS commits

The DebOps project provides a set of general-purpose Ansible roles that can be used to manage Debian or Ubuntu hosts. In addition, a default set of Ansible playbooks can be used to apply the provided roles in a controlled way, using Ansible inventory groups.

The roles are written with a high customization in mind, which can be done using Ansible inventory. This way the role and playbook code can be shared between multiple environments, with different configuration in to each one.

Services can be managed on a single host, or spread between multiple hosts. DebOps provides support for different SQL and NoSQL databases, web servers, programming languages and specialized applications useful in a data center environment or in a cluster. The project can also be used to deploy virtualization environments using KVM/libvirt, Docker or LXC technologies to manage virtual machines and/or containers.

You can find out more about DebOps features on the project's documentation page.

Quick start

Start a Docker container which acts as an Ansible Controller host with DebOps support, based on Debian Buster:

docker run -it --rm debops/debops
cd src/controller ; debops run common --diff

Or, create a Vagrant VM which acts as an Ansible Controller host:

git clone https://github.com/debops/debops
cd debops && vagrant up && vagrant ssh
cd src/controller ; debops run common --diff

You can use configuration in the src/controller subdirectory to try out DebOps against the container/VM, or create your own DebOps project directory using debops project init command.

More quick start tips can be found in the DebOps quick start guide.

Installation

You can install the DebOps Python package, which includes the DebOps roles and playbooks, as well as additional scripts which can be used to setup separate project directories and run Ansible in a convenient way. To install the Python package with Ansible and other required dependencies, run the command:

pip install --user debops[ansible]

Alternatively, DebOps roles are available on Ansible Galaxy as an Ansible Collection which can be installed using the ansible-galaxy command:

ansible-galaxy collection install debops.debops

Read the installation instructions in the DebOps documentation for more details about required software and dependencies.

Getting started

Ansible uses SSH to connect to and manage the hosts. DebOps enforces the SSH security by disabling password authentication, therefore using SSH keys to connect to the hosts is strongly recommended. This can be changed using the inventory variables.

During initial deployments you might find that the firewall created by DebOps blocked you from accessing the hosts. Because of that it's advisable to have an out-of-band console access to the host which can be used to login and troubleshoot the connection.

Create a new environment within a DebOps "project directory", add some hosts in the Ansible inventory and run the default DebOps playbook against them to configure them:

# Create a new environment
debops project init ~/src/projects/my-environment
cd ~/src/projects/my-environment

# Modify the 'ansible/inventory/hosts' file to suit your needs, for example
# uncomment the local host to configure it with DebOps

# Run the full playbook against all hosts in the inventory
debops run site

# Run the common playbook against specific host in the inventory
debops run common -l <hostname>

You should read the Getting Started with DebOps guide for a more in-depth explanation of how the project can be used to manage multiple hosts via Ansible.

Development

Create a fork of this repository and clone it to your workstation. Create a development DebOps environment and symlink the forked repository in it. Now you can create new playbooks/roles in the forked repository and see their results in the development environment.

git clone [email protected]:<username>/debops ~/src/github.com/<username>/debops
cd ~/src/github.com/<username>/debops
git remote add upstream https://github.com/debops/debops.git

debops project init ~/src/projects/debops-devel
cd ~/src/projects/debops-devel
ln -s ~/src/github.com/<username>/debops debops

You can pull latest changes to the project from the upstream repository:

cd ~/src/github.com/<username>/debops
git checkout master
git fetch upstream
git rebase upstream/master

Read the development guide file for more details about the DebOps development process.

Contributing

DebOps development is done via a distributed development model. New features and changes are prepared in a fork of the official repository and are published to the original repository via GitHub pull requests. PRs are reviewed by the DebOps developer team and if accepted, are merged in the main repository.

GPG-signed git commits are preferred to ensure authenticity.

Read the contributing guide file for more details about how to contribute to DebOps.

Licensing

The DebOps project is licensed under the GNU General Public License 3.0 or later. You can find full text of the license in the LICENSES/GPL-3.0-or-later.txt file.

Some files included with the DebOps project use a different license. The licenses are marked in these files using the SPDX license identifiers and can be found in the LICENSES/ subdirectory. They are also included in the project tarballs, Ansible Collections and Python packages. The project uses the REUSE Specification and its associated tool to check and verify copyright and license information in all files.

ansible-gitlab's People

Contributors

anzil avatar benalbrecht avatar bfabio avatar drybjed avatar gomez avatar oldkarkass avatar scibi avatar xorgic avatar ypid 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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

ansible-gitlab's Issues

"Initialize GitLab database" task fails, when generated db password starts with a comma

TASK: [debops.gitlab | Initialize GitLab database] **************************** 
failed: [gitlab] => {"changed": true, "cmd": "yes 'yes' | bundle exec rake gitlab:setup RAILS_ENV=production", "delta": "0:00:21.898264", "end": "2015-11-10 11:01:05.811259", "rc": 1, "start": "2015-11-10 11:00:43.912995", "warnings": []}
stderr: rake aborted!
YAML syntax error occurred while parsing /var/local/git/gitlab/config/database.yml.
Please note that YAML must be consistently indented using spaces. Tabs are not allowed. 
Error: (<unknown>): did not find expected node content while parsing a block node at line 12 column 13

Line 12 contains the password, column 13 is the comma

  password: ,L1PZf:bu.XOIyetc...

Generated passwords contain a random mix of upper and lowercase ASCII letters, the numbers 0-9 and punctuation (โ€. , : - _โ€).
http://docs.ansible.com/ansible/playbooks_lookups.html#the-password-lookup

restricting the set of allowed characters in the password should help.
the following line allows all of the default characters except the comma:

gitlab_database_password: "{{ lookup('password', gitlab_database_password_path + ' length=48 chars=ascii_letters,digits,.:-_') }}"

Permission problems in a clean installation

In a clean installation /var/local/git/gitlab/log/unicorn.stderr.log log the following errors:

I, [2015-10-02T04:46:41.570908 #27653]  INFO -- : Refreshing Gem list
Rails Error: Unable to access log file. Please ensure that /var/local/git/gitlab/log/production.log exists and is chmod 0666. The log level has been raised to WARN and the output directed to STDERR until the problem is fixed.
/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/application.rb:339:in `read': Permission denied @ rb_sysopen - /var/local/git/gitlab/config/secrets.yml (Errno::EACCES)
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/application.rb:339:in `secrets'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/railtie.rb:194:in `public_send'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/railtie.rb:194:in `method_missing'
    from /var/local/git/gitlab/config/initializers/secret_token.rb:33:in `<top (required)>'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.12/lib/active_support/dependencies.rb:241:in `load'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.12/lib/active_support/dependencies.rb:241:in `block in load'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.12/lib/active_support/dependencies.rb:232:in `load_dependency'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.12/lib/active_support/dependencies.rb:241:in `load'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/engine.rb:648:in `block in load_config_initializer'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.12/lib/active_support/notifications.rb:161:in `instrument'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/engine.rb:647:in `load_config_initializer'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/engine.rb:612:in `block (2 levels) in <class:Engine>'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/engine.rb:611:in `each'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/engine.rb:611:in `block in <class:Engine>'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/initializable.rb:30:in `instance_exec'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/initializable.rb:30:in `run'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/initializable.rb:55:in `block in run_initializers'
    from /usr/lib/ruby/2.1.0/tsort.rb:226:in `block in tsort_each'
    from /usr/lib/ruby/2.1.0/tsort.rb:348:in `block (2 levels) in each_strongly_connected_component'
    from /usr/lib/ruby/2.1.0/tsort.rb:418:in `block (2 levels) in each_strongly_connected_component_from'
    from /usr/lib/ruby/2.1.0/tsort.rb:427:in `each_strongly_connected_component_from'
    from /usr/lib/ruby/2.1.0/tsort.rb:417:in `block in each_strongly_connected_component_from'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/initializable.rb:44:in `each'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/initializable.rb:44:in `tsort_each_child'
    from /usr/lib/ruby/2.1.0/tsort.rb:411:in `call'
    from /usr/lib/ruby/2.1.0/tsort.rb:411:in `each_strongly_connected_component_from'
    from /usr/lib/ruby/2.1.0/tsort.rb:347:in `block in each_strongly_connected_component'
    from /usr/lib/ruby/2.1.0/tsort.rb:345:in `each'
    from /usr/lib/ruby/2.1.0/tsort.rb:345:in `call'
    from /usr/lib/ruby/2.1.0/tsort.rb:345:in `each_strongly_connected_component'
    from /usr/lib/ruby/2.1.0/tsort.rb:224:in `tsort_each'
    from /usr/lib/ruby/2.1.0/tsort.rb:205:in `tsort_each'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/initializable.rb:54:in `run_initializers'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/application.rb:300:in `initialize!'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/railtie.rb:194:in `public_send'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/railties-4.1.12/lib/rails/railtie.rb:194:in `method_missing'
    from /var/local/git/gitlab/config/environment.rb:5:in `<top (required)>'
    from config.ru:16:in `require'
    from config.ru:16:in `block in <main>'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rack-1.5.5/lib/rack/builder.rb:55:in `instance_eval'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rack-1.5.5/lib/rack/builder.rb:55:in `initialize'
    from config.ru:1:in `new'
    from config.ru:1:in `<main>'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn.rb:48:in `eval'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn.rb:48:in `block in builder'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/bin/unicorn_rails:139:in `call'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/bin/unicorn_rails:139:in `block in rails_builder'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:764:in `call'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:764:in `build_app!'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:137:in `start'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/bin/unicorn_rails:209:in `<top (required)>'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/bin/unicorn_rails:23:in `load'
    from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/bin/unicorn_rails:23:in `<main>'

The result is a 502 error in browser.

upgrade to 8.0 seems to miss gem install

I tried to upgrade, but it failed with /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/spec_set.rb:92:inblock in materialize': Could not find CFPropertyList-2.3.1 in any of the sources (Bundler::GemNotFound)

TASK: [debops.gitlab | Display deploy.html page] ****************************** 
ok: [default]

TASK: [debops.gitlab | Stop Sidekiq before upgrade] *************************** 
failed: [default] => {"changed": true, "cmd": "bundle exec rake sidekiq:stop RAILS_ENV=production", "delta": "0:00:00.359893", "end": "2015-09-25 12:24:08.907041", "rc": 1, "start": "2015-09-25 12:24:08.547148", "warnings": []}
stderr: /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/spec_set.rb:92:in `block in materialize': Could not find CFPropertyList-2.3.1 in any of the sources (Bundler::GemNotFound)
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/spec_set.rb:85:in `map!'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/spec_set.rb:85:in `materialize'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/definition.rb:132:in `specs'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/definition.rb:177:in `specs_for'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/definition.rb:166:in `requested_specs'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/environment.rb:18:in `requested_specs'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/runtime.rb:13:in `setup'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler.rb:122:in `setup'
    from /var/lib/gems/2.1.0/gems/bundler-1.9.9/lib/bundler/setup.rb:18:in `<top (required)>'
    from /usr/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from /usr/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'

Running

git@debian-jessie-amd64-netboot:~/gitlab$ bundle exec rake sidekiq:stop RAILS_ENV=production
Could not find CFPropertyList-2.3.1 in any of the sources
Run `bundle install` to install missing gems.
git@debian-jessie-amd64-netboot:~/gitlab$ bundle install
Fetching gem metadata from https://rubygems.org/.......
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Using rake 10.4.2
Installing CFPropertyList 2.3.1
Using RedCloth 4.2.9
Using ace-rails-ap 2.0.1
Using i18n 0.7.0
Installing json 1.8.3
Installing minitest 5.7.0
Using thread_safe 0.3.5
...
...
...
Bundle complete! 153 Gemfile dependencies, 242 gems now installed.
Gems in the groups development, test, aws and postgres were not installed.
Bundled gems are installed into ./vendor/bundle.

installs many many gems.
Once it's finished, the task works fine.

I guess that you cannot use the rakefile when the dependencies are not met.
And the dependencies changed when the git repository was updated.
So I guess that a when: git_update | changed, then gem install is needed.

Gitlab 8.0 not working on wheezy (golang to old)

Got this error:

go build -ldflags "-X main.Version 0.2.10-20150928.143221" -o gitlab-git-http-server
# _/var/local/gitlab/gitlab-git-http-server
./githandler.go:113: undefined: strings.TrimSuffix
./githandler.go:257: undefined: strings.TrimPrefix

Fix:
apt-get -t wheezy-backports install golang

This needs to go into docs.

Drop support for old versions

We should drop support for versions older than $VERSION to keep the complexity down, since the usefulness of old versions is limited and the upgrade path from and to arbitrary versions is not tested anyway.

$VERSION should be somewhere into the 8.x series IMO.

Gitlab fails on initializing DB

Hello,

try to install gitlab on a debian-based system.
The first run of debops throws the following error. The second run throws no error, but gitlab isnt reacable.

debops inventory:

``
[debops_all_hosts]
testing

[debops_service_gitlab]
testing
``

taget-system: vagrant box with "debian/jessie64"

error message:

TASK [debops.gitlab : Initialize GitLab database] ****************************** fatal: [testing]: FAILED! => {"changed": true, "cmd": "yes 'yes' | bundle exec rake gitlab:setup RAILS_ENV=production", "delta": "0:00:06.357969", "end": "2016-10-29 23:24:29.973947", "failed": true, "rc": 1, "start": "2016-10-29 23:24:23.615978", "stderr": "Missing Rails.application.secrets.secret_key_base for production environment. The secret will be generated and stored in config/secrets.yml.\nMissing Rails.application.secrets.otp_key_base for production environment. The secret will be generated and stored in config/secrets.yml.\nMissing Rails.application.secrets.db_key_base for production environment. The secret will be generated and stored in config/secrets.yml.\nCan't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/mysql2-0.3.20/lib/mysql2/client.rb:70:inconnect'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/mysql2-0.3.20/lib/mysql2/client.rb:70:in initialize'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in new'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in mysql2_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:438:in new_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:448:in checkout_new_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:422:in acquire_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:349:in block in checkout'\n/usr/lib/ruby/2.1.0/monitor.rb:211:in mon_synchronize'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:348:in checkout'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:263:in block in connection'\n/usr/lib/ruby/2.1.0/monitor.rb:211:in mon_synchronize'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:262:in connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:571:in retrieve_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_handling.rb:113:in retrieve_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_handling.rb:87:in connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/mysql_database_tasks.rb:8:in connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/mysql_database_tasks.rb:42:in drop'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:114:in drop'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:128:in block in drop_current'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:276:in block in each_current_configuration'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:275:in each'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:275:in each_current_configuration'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:127:in drop_current'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/railties/databases.rake:28:in block (2 levels) in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:240:in call'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:240:in block in execute'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:235:in each'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:235:in execute'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:179:in block in invoke_with_call_chain'\n/usr/lib/ruby/2.1.0/monitor.rb:211:in mon_synchronize'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:172:in invoke_with_call_chain'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:165:in invoke'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/railties/databases.rake:141:in block (2 levels) in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:240:in call'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:240:in block in execute'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:235:in each'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:235:in execute'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:179:in block in invoke_with_call_chain'\n/usr/lib/ruby/2.1.0/monitor.rb:211:in mon_synchronize'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:172:in invoke_with_call_chain'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:165:in invoke'\n/var/local/git/gitlab/lib/tasks/gitlab/setup.rake:17:in setup_db'\n/var/local/git/gitlab/lib/tasks/gitlab/setup.rake:4:in block (2 levels) in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:240:in call'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:240:in block in execute'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:235:in each'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:235:in execute'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:179:in block in invoke_with_call_chain'\n/usr/lib/ruby/2.1.0/monitor.rb:211:in mon_synchronize'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:172:in invoke_with_call_chain'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/task.rb:165:in invoke'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:150:in invoke_task'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:106:in block (2 levels) in top_level'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:106:in each'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:106:in block in top_level'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:115:in run_with_threads'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:100:in top_level'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:78:in block in run'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:176:in standard_exception_handling'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/lib/rake/application.rb:75:in run'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rake-10.5.0/bin/rake:33:in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/bin/rake:23:in load'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/bin/rake:23:in <main>'\nCouldn't drop gitlabhq_production\n#<Mysql2::Error: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)>\nCouldn't create database for {\"adapter\"=>\"mysql2\", \"encoding\"=>\"utf8\", \"reconnect\"=>false, \"database\"=>\"gitlabhq_production\", \"pool\"=>10, \"username\"=>\"gitlab\", \"password\"=>\"AdHjIOmKryq-gEp_lAQEeIww:8LKn3T4WKzkezvPSRh3W3mf\", \"host\"=>nil}, {:charset=>\"utf8\", :collation=>\"utf8_unicode_ci\"}\n(If you set the charset manually, make sure you have a matching collation)\nrake aborted!\nMysql2::Error: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/mysql2-0.3.20/lib/mysql2/client.rb:70:in connect'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/mysql2-0.3.20/lib/mysql2/client.rb:70:in initialize'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in new'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in mysql2_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:438:in new_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:448:in checkout_new_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:422:in acquire_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:349:in block in checkout'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:348:in checkout'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:263:in block in connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:262:in connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:571:in retrieve_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_handling.rb:113:in retrieve_connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/connection_handling.rb:87:in connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/migration.rb:648:in connection'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/migration.rb:664:in block in method_missing'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/migration.rb:634:in block in say_with_time'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/migration.rb:634:in say_with_time'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/migration.rb:654:in method_missing'\n/var/local/git/gitlab/db/schema.rb:17:in block in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/schema.rb:41:in instance_eval'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/schema.rb:41:in define'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/schema.rb:61:in define'\n/var/local/git/gitlab/db/schema.rb:14:in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.2.7.1/lib/active_support/dependencies.rb:268:in load'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.2.7.1/lib/active_support/dependencies.rb:268:in block in load'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.2.7.1/lib/active_support/dependencies.rb:240:in load_dependency'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.2.7.1/lib/active_support/dependencies.rb:268:in load'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:219:in load_schema_for'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:236:in block in load_schema_current'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:276:in block in each_current_configuration'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:275:in each'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:275:in each_current_configuration'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/tasks/database_tasks.rb:235:in load_schema_current'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/railties/databases.rake:247:in block (3 levels) in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/railties/databases.rake:251:in block (3 levels) in <top (required)>'\n/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.2.7.1/lib/active_record/railties/databases.rake:142:in block (2 levels) in <top (required)>'\n/var/local/git/gitlab/lib/tasks/gitlab/setup.rake:17:in setup_db'\n/var/local/git/gitlab/lib/tasks/gitlab/setup.rake:4:in block (2 levels) in <top (required)>'\nTasks: TOP => db:schema:load\n(See full trace by running task with --trace)\nyes: standard output: Broken pipe\nyes: write error", "stdout": "This will create the necessary database tables and seed the database.\nYou will lose any previous data stored in the database.\nDo you want to continue (yes/no)? \n-- enable_extension("plpgsql")", "stdout_lines": ["This will create the necessary database tables and seed the database.", "You will lose any previous data stored in the database.", "Do you want to continue (yes/no)? ", "-- enable_extension("plpgsql")"], "warnings": []}
`

Intermmitting login problems

After one day of trial and error lunching debops I noticed some intermittent login problem to the server managed by debops.
I debugged the login and discovered that the common.yml script has changed something inspected to me.
Here the auth.log then I try to execute debops again:

Mar 30 17:22:34 laptop sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:34 laptop sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 Abortu sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 Abortu sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 Abortu sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 Abortu sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 Abortu sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 Abortu sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): auth could not identify password for [user]
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): conversation failed
Mar 30 17:22:35 laptop sudo: pam_unix(sudo:auth): auth could not identify password for [user]

and here one of the errors I get from debops:

fatal: [srv2] => Missing become password

What can be?

Documentation reg. admin login not very clear

Currently, it reads "The credentials are saved in the secrets dir secret/credentials/host/gitlab/admin/password The login is admin@host".

That information, however, is not entirely accurate. The only user configured for gitlab seems to be the user with the login gitlab_admin_email which defaults to user@{{ ansible_domain }}. That information would be good to have. It would probably also be good to save that username along with the password in the secret folder or print it out during provisioning.

gitlab install with postgresql failed

I enabled postgres with gitlab_database: 'postgresql' this happend on db init:

I, [2015-02-10T11:11:14.439024 #10021]  INFO -- : Refreshing Gem list
/var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/postgresql_adapter.rb:881:in `initialize': FATAL:  no pg_hba.conf entry for host "[local]", user "git", database "gitlabhq_production", SSL off (PG::Error)
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/postgresql_adapter.rb:881:in `new'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/postgresql_adapter.rb:881:in `connect'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/postgresql_adapter.rb:568:in `initialize'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/postgresql_adapter.rb:41:in `new'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/postgresql_adapter.rb:41:in `postgresql_connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:435:in `new_connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:445:in `checkout_new_connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:416:in `acquire_connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:351:in `block in checkout'
        from /usr/lib/ruby/2.1.0/monitor.rb:211:in `mon_synchronize'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:350:in `checkout'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:265:in `block in connection'
        from /usr/lib/ruby/2.1.0/monitor.rb:211:in `mon_synchronize'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:264:in `connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:541:in `retrieve_connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_handling.rb:113:in `retrieve_connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/connection_handling.rb:87:in `connection'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activerecord-4.1.1/lib/active_record/model_schema.rb:209:in `table_exists?'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/acts-as-taggable-on-2.4.1/lib/acts_as_taggable_on/acts_as_taggable_on/cache.rb:5:in `included'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/acts-as-taggable-on-2.4.1/lib/acts_as_taggable_on/taggable.rb:98:in `include'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/acts-as-taggable-on-2.4.1/lib/acts_as_taggable_on/taggable.rb:98:in `taggable_on'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/acts-as-taggable-on-2.4.1/lib/acts_as_taggable_on/taggable.rb:39:in `acts_as_taggable_on'
        from /var/local/git/gitlab/app/models/project.rb:45:in `<class:Project>'
        from /var/local/git/gitlab/app/models/project.rb:29:in `<top (required)>'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `block in require'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:348:in `require_or_load'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:480:in `load_missing_constant'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:180:in `const_missing'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:512:in `load_missing_constant'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:180:in `const_missing'
        from /var/local/git/gitlab/app/models/forked_project_link.rb:13:in `<class:ForkedProjectLink>'
        from /var/local/git/gitlab/app/models/forked_project_link.rb:12:in `<top (required)>'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `block in require'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
        from /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:348:in `require_or_load'

The gitlab user does not have rights for the /etc/postgresql/9.1/main/pg_hba.conf.

I am not a postgresql admin, was just a test.

Support for omnibus package installation

First thank a lot for this amazing work.

The actual installation follows the manual installation method. This method has the following issues:

  • Long to run
  • Complex to maintain
  • Backups from package installation are not compatible with source installation

Is there a way to support the installation using the gitlab package server as described in gitlab's website?

Custom Ansible

I already have existing ansible directory, how can I use this with my existing setup without needing to install all the PIP requirements and scripts?

"Update Ruby gems" fails on Debian Jessie

I'm trying to install GitLab on fresh Jessie installation. It fails because of lack of pkg-config:

TASK: [debops.gitlab | Update Ruby gems] ************************************** 
failed: [git] => {"changed": true, "cmd": "bundle install --deployment --without development test aws postgres", "delta": "0:03:46.467941", "end": "2015-03-25 15:24:36.542570", "rc": 5, "start": "2015-03-25 15:20:50.074629", "warnings": []}
stdout: Fetching gem metadata from https://rubygems.org/.......
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Installing rake 10.3.2
Installing RedCloth 4.2.9
Installing ace-rails-ap 2.0.1
Installing i18n 0.7.0
Installing json 1.8.2
Installing minitest 5.3.5
Installing thread_safe 0.3.4
Installing tzinfo 1.2.2
Installing activesupport 4.1.1
Installing builder 3.2.2
Installing erubis 2.7.0
Installing actionview 4.1.1
Installing rack 1.5.2
Installing rack-test 0.6.2
Installing actionpack 4.1.1
Installing mime-types 1.25.1
Installing polyglot 0.3.4
Installing treetop 1.4.15
Installing mail 2.5.4
Installing actionmailer 4.1.1
Installing activemodel 4.1.1
Installing arel 5.0.1.20140414130214
Installing activerecord 4.1.1
Installing rails-observers 0.1.2
Installing activeresource 4.0.0
Using bundler 1.9.1
Installing thor 0.19.1
Installing railties 4.1.1
Installing hike 1.2.3
Installing multi_json 1.10.1
Installing tilt 1.4.1
Installing sprockets 2.11.0
Installing sprockets-rails 2.1.3
Installing rails 4.1.1
Installing acts-as-taggable-on 2.4.1
Installing addressable 2.3.5
Installing asana 0.0.6
Installing asciidoctor 0.1.4
Installing attr_required 1.0.0
Installing descendants_tracker 0.0.3
Installing ice_nine 0.10.0
Installing axiom-types 0.0.5
Installing bcrypt 3.1.7
Installing sass 3.2.19
Installing bootstrap-sass 3.0.3.0
Installing browser 0.7.2
Installing cal-heatmap-rails 0.0.1
Installing carrierwave 0.9.0
Installing hitimes 1.2.2
Installing timers 4.0.1
Installing celluloid 0.16.0
Installing charlock_holmes 0.6.9.4
Installing coercible 1.0.0
Installing coffee-script-source 1.6.3
Installing execjs 2.0.2
Installing coffee-script 2.2.0
Installing coffee-rails 4.0.1
Installing colored 1.2
Installing connection_pool 2.1.0
Installing creole 0.3.8
Installing d3_rails 3.1.10
Installing default_value_for 3.0.0
Installing orm_adapter 0.5.0
Installing warden 1.2.3
Installing devise 3.2.4
Installing devise-async 0.9.0
Installing diff-lcs 1.2.5
Installing diffy 3.0.3
Installing doorkeeper 2.1.0
Installing dotenv 0.9.0
Installing dropzonejs-rails 0.4.14
Installing emoji 1.0.1
Installing enumerize 0.7.0
Installing equalizer 0.0.8
Installing escape_utils 0.2.4
Installing eventmachine 1.0.4
Installing excon 0.32.1
Installing expression_parser 0.9.0
Installing multipart-post 1.2.0
Installing faraday 0.8.9
Installing faraday_middleware 0.9.0
Installing formatador 0.2.4
Installing net-ssh 2.8.0
Installing net-scp 1.1.2
Installing fog-core 1.21.1
Installing fog-json 1.0.0
Installing fog-brightbox 0.0.1
Installing mini_portile 0.6.1
Installing nokogiri 1.6.5
Installing fog 1.21.0
Installing font-awesome-rails 4.2.0.0
Installing foreman 0.63.0

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    /usr/bin/ruby2.1 extconf.rb 
checking for cmake... yes
checking for gmake... no
checking for make... yes
checking for pkg-config... no
ERROR: pkg-config is required to build Rugged.
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers.  Check the mkmf.log file for more details.  You may
need configuration options.

Provided configuration options:
    --with-opt-dir
    --without-opt-dir
    --with-opt-include
    --without-opt-include=${opt-dir}/include
    --with-opt-lib
    --without-opt-lib=${opt-dir}/lib
    --with-make-prog
    --without-make-prog
    --srcdir=.
    --curdir
    --ruby=/usr/bin/ruby2.1

extconf failed, exit code 1

Gem files will remain installed in /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/rugged-0.21.2 for inspection.
Results logged to /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/extensions/x86_64-linux/2.1.0/rugged-0.21.2/gem_make.out
An error occurred while installing rugged (0.21.2), and Bundler cannot continue.
Make sure that `gem install rugged -v '0.21.2'` succeeds before bundling.

FATAL: all hosts have already failed -- aborting

updating ruby gems is not re-attempted on failure

When installation of gitlab fails due to a missing libkrb5-dev, i.e.

TASK: [debops.gitlab | Update Ruby gems] ************************************** 
<192.168.121.245> REMOTE_MODULE command bundle install --deployment --without development test aws postgres chdir=/var/local/git/gitlab #USE_SHELL
failed: [vagrant_gitlab] => {"changed": true, "cmd": "bundle install --deployment --without development test aws postgres", "delta": "0:06:10.574651", "end": "2015-05-21 14:57:04.993957", "rc": 5, "start": "2015-05-21 14:50:54.419306", "warnings": []}
stdout: Fetching gem metadata from https://rubygems.org/........
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Installing rake 10.4.2
Installing RedCloth 4.2.9
Installing ace-rails-ap 2.0.1
Installing i18n 0.7.0
Installing json 1.8.2
Installing minitest 5.3.5
Installing thread_safe 0.3.5
Installing tzinfo 1.2.2
Installing activesupport 4.1.9
Installing builder 3.2.2
Installing erubis 2.7.0
Installing actionview 4.1.9
Installing rack 1.5.2
Installing rack-test 0.6.3
Installing actionpack 4.1.9
Installing mime-types 1.25.1
Installing mail 2.6.3
Installing actionmailer 4.1.9
Installing activemodel 4.1.9
Installing arel 5.0.1.20140414130214
Installing activerecord 4.1.9
Installing rails-observers 0.1.2
Installing activeresource 4.0.0
Using bundler 1.9.9
....
TASK: [debops.gitlab | Update Ruby gems] ************************************** 
<192.168.121.245> REMOTE_MODULE command bundle install --deployment --without development test aws postgres chdir=/var/local/git/gitlab #USE_SHELL
failed: [vagrant_gitlab] => {"changed": true, "cmd": "bundle install --deployment --without development test aws postgres", "delta": "0:06:10.574651", "end": "2015-05-21 14:57:04.993957", "rc": 5, "start": "2015-05-21 14:50:54.419306", "warnings": []}
stdout: Fetching gem metadata from https://rubygems.org/........
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Installing rake 10.4.2
Installing RedCloth 4.2.9
Installing ace-rails-ap 2.0.1
Installing i18n 0.7.0
Installing json 1.8.2
Installing minitest 5.3.5
Installing thread_safe 0.3.5
Installing tzinfo 1.2.2
Installing activesupport 4.1.9
Installing builder 3.2.2
Installing erubis 2.7.0
Installing actionview 4.1.9
Installing rack 1.5.2
Installing rack-test 0.6.3
Installing actionpack 4.1.9
Installing mime-types 1.25.1
Installing mail 2.6.3
Installing actionmailer 4.1.9
Installing activemodel 4.1.9
Installing arel 5.0.1.20140414130214
Installing activerecord 4.1.9
Installing rails-observers 0.1.2
Installing activeresource 4.0.0
Using bundler 1.9.9

then running debops does not try to execute that task again.

Gitlab installation fails due to missing ruby-dev package

When installaing gitlab, the installation fails at various points. When running a manual bundle install the root cause is shown:

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    /usr/bin/ruby2.1 extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h

extconf failed, exit code 1

Gem files will remain installed in /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/gems/version_sorter-2.0.0 for inspection.
Results logged to /var/local/git/gitlab/vendor/bundle/ruby/2.1.0/extensions/x86_64-linux/2.1.0/version_sorter-2.0.0/gem_make.out
An error occurred while installing RedCloth (4.3.2), and Bundler cannot continue.
Make sure that `gem install RedCloth -v '4.3.2'` succeeds before bundling.

Seems that the ruby-dev package is required for the native extension build to run.

RFC: Drop MySQL/MariaDB support

Rationale:
The role is quite complex by itself, the reasons being:

  • The fast pace upstream develops GitLab (this would be enough work already).
  • Support for different GitLab versions
  • Support for different distros
  • Support for both MySQL/MariaDB and PostgreSQL.

Supporting all those possible premutations makes the complexity explode really fast.

My proposal is to drop at least MySQL/MariaDB, as per
https://docs.gitlab.com/ce/install/requirements.html#database, where they strongly hint not to use MySQL and mention some features are even missing when you do.

Also, there are other pain points not mentioned I experienced myself with character encodings which we just don't handle. There is a whole document describing how to unfuck that mess.

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.