Skip to content

Instantly share code, notes, and snippets.

@spuder
Created October 1, 2014 22:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save spuder/c820f28498786bb29e39 to your computer and use it in GitHub Desktop.
Save spuder/c820f28498786bb29e39 to your computer and use it in GitHub Desktop.
gitlab git user
[root@gitlab tmp]# gitlab-ctl reconfigure
Starting Chef Client, version 11.12.2
Compiling Cookbooks...
Recipe: gitlab::default
* directory[/etc/gitlab] action create (up to date)
[2014-10-01T16:41:46-06:00] WARN: Cloning resource attributes for directory[/var/opt/gitlab] from prior resource (CHEF-3694)
[2014-10-01T16:41:46-06:00] WARN: Previous directory[/var/opt/gitlab]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/default.rb:40:in `from_file'
[2014-10-01T16:41:46-06:00] WARN: Current directory[/var/opt/gitlab]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/users.rb:23:in `from_file'
[2014-10-01T16:41:46-06:00] WARN: Cloning resource attributes for directory[/var/opt/gitlab/gitlab-rails/etc] from prior resource (CHEF-3694)
[2014-10-01T16:41:46-06:00] WARN: Previous directory[/var/opt/gitlab/gitlab-rails/etc]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/gitlab-rails.rb:37:in `block in from_file'
[2014-10-01T16:41:46-06:00] WARN: Current directory[/var/opt/gitlab/gitlab-rails/etc]: /opt/gitlab/embedded/cookbooks/gitlab/definitions/unicorn_config.rb:21:in `block in from_file'
[2014-10-01T16:41:46-06:00] WARN: Cloning resource attributes for service[unicorn] from prior resource (CHEF-3694)
[2014-10-01T16:41:46-06:00] WARN: Previous service[unicorn]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/default.rb:60:in `block in from_file'
[2014-10-01T16:41:46-06:00] WARN: Current service[unicorn]: /opt/gitlab/embedded/cookbooks/runit/definitions/runit_service.rb:191:in `block in from_file'
[2014-10-01T16:41:46-06:00] WARN: Cloning resource attributes for service[sidekiq] from prior resource (CHEF-3694)
[2014-10-01T16:41:46-06:00] WARN: Previous service[sidekiq]: /opt/gitlab/embedded/cookbooks/gitlab/recipes/default.rb:60:in `block in from_file'
[2014-10-01T16:41:46-06:00] WARN: Current service[sidekiq]: /opt/gitlab/embedded/cookbooks/runit/definitions/runit_service.rb:191:in `block in from_file'
Converging 159 resources
* directory[/etc/gitlab] action nothing (skipped due to action :nothing)
* directory[/var/opt/gitlab] action create (up to date)
Recipe: gitlab::users
* directory[/var/opt/gitlab] action create (up to date)
* group[git] action create
================================================================================
Error executing action `create` on resource 'group[git]'
================================================================================
Chef::Exceptions::Exec
----------------------
groupmod git returned 10, expected 0
Resource Declaration:
---------------------
# In /opt/gitlab/embedded/cookbooks/gitlab/recipes/users.rb
28: group gitlab_group do
29: gid node['gitlab']['user']['gid']
30: end
31:
Compiled Resource:
------------------
# Declared in /opt/gitlab/embedded/cookbooks/gitlab/recipes/users.rb:28:in `from_file'
group("git") do
action :create
retries 0
retry_delay 2
guard_interpreter :default
group_name "git"
gid 2104
cookbook_name :gitlab
recipe_name "users"
end
Running handlers:
[2014-10-01T16:41:46-06:00] ERROR: Running exception handlers
Running handlers complete
[2014-10-01T16:41:46-06:00] ERROR: Exception handlers complete
[2014-10-01T16:41:46-06:00] FATAL: Stacktrace dumped to /opt/gitlab/embedded/cookbooks/cache/chef-stacktrace.out
Chef Client failed. 0 resources updated in 2.447527044 seconds
[2014-10-01T16:41:47-06:00] ERROR: group[git] (gitlab::users line 28) had an error: Chef::Exceptions::Exec: groupmod git returned 10, expected 0
[2014-10-01T16:41:47-06:00] FATAL: Chef::Exceptions::ChildConvergeError: Chef run process exited unsuccessfully (exit code 1)
@spuder
Copy link
Author

spuder commented Oct 1, 2014

Everytime I try and install gitlab, it errors out while trying to add the git user.

There is no git user on the machine, but there is a git user in ldap, I wonder if that might be the problem?

[root@gitlab tmp]# id git
id: git: No such user

@gamerlv
Copy link

gamerlv commented Oct 2, 2014

It isn't erring on the user git, it's trying to create the user group git.
Try removing the existing one using groupdel git and then rerunning the omnibus installer

@spuder
Copy link
Author

spuder commented Oct 2, 2014

Thanks, @gamerlv

Looks like that doesn't work.

groupdel git
groupdel: cannot remove entry 'git' from /etc/group

I'm thinking I may be able to use a different user

https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/files/gitlab-cookbooks/gitlab/attributes/default.rb

I've also opened an issue on this.
https://gitlab.com/gitlab-org/omnibus-gitlab/issues/271

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment