Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rbenv user ID should be settable by an attribute #76

Open
sentience opened this issue Nov 14, 2013 · 0 comments
Open

rbenv user ID should be settable by an attribute #76

sentience opened this issue Nov 14, 2013 · 0 comments

Comments

@sentience
Copy link

Recipe rbenv::default creates a user rbenv:

user node[:rbenv][:user] do
  shell "/bin/bash"
  group node[:rbenv][:group]
  supports :manage_home => node[:rbenv][:manage_home]
end

Because no numeric user ID is specified here, the next available user ID is selected. This can interfere with essential cookbooks such as users later adding additional users to the machine with specific IDs.

Here’s how this bit me in my case:

  1. Provisioned a new node, which did this:
    • users::default created users with specified IDs 2001, 2002, 2003.
    • rbenv::default created user rbenv with auto-assigned user ID 2004.
  2. At some later date, on my Chef Server, specified a new user in the sequence of IDs: 2004.
  3. The next chef-client run on the existing node failed because ID 2004 was taken by the rbenv user.

I suggest that a default numeric ID should be specified for the rbenv user, and configurable using an attribute:

user node[:rbenv][:user] do
  shell "/bin/bash"
  uid node[:rbenv][:user_uid] # <--
  group node[:rbenv][:group]
  supports :manage_home => node[:rbenv][:manage_home]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant