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

Change root group references to use GID 0 #225

Closed
wants to merge 1 commit into from
Closed

Change root group references to use GID 0 #225

wants to merge 1 commit into from

Conversation

xenophonf
Copy link
Contributor

Summary of Changes

  • On BSD the group with GID 0 is named wheel.
  • Rather than change the group name on a per-operating system basis, it's simpler to reference the group by GID.
  • Only change SLS files that apply to both Linux and FreeBSD.
    Testing
  • Tested manually on FreeBSD

On BSD this group is named `wheel`.  Rather than change the group name
on a per-operating system basis, it's simpler to reference the group
by GID.
@ze42
Copy link
Contributor

ze42 commented May 22, 2018

... has it been tested and working?

In old version (up to at least 2017.7.4), user: 0 or gid: 0 would not get any change.

if x['user']: -- implicitly converted to bool, and 0 means false...

@aboe76
Copy link
Member

aboe76 commented Nov 7, 2018

isn't it better to have this variable set via map.jinja as a string
something like 'tls_user' and 'tls_group' ?

@alxwr
Copy link
Member

alxwr commented Nov 7, 2018

I agree with @aboe76 . Using a variable is always better than hardcoding stuff.
group: 0 would just replace a (failed) assumption with another one. (It may be correct that root's group has GID 0 on all *nix systems, but we can't know if we cover all use cases.)

@ze42
Copy link
Contributor

ze42 commented Nov 8, 2018

Yeah, two options I'd see working:

  • have the group in a map, with root being the default value, and BSD defining it to wheel
  • get salt to fix its code

Guess the second is not easy, so a map would work fine.

@xenophonf
Copy link
Contributor Author

I wasn't aware of that bug in Salt. A map is better. Let me see if I can fix the pull request. If not, I'll resubmit it. Thanks for the feedback!

@noelmcloughlin
Copy link
Member

Included in #283

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

Successfully merging this pull request may close these issues.

5 participants