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

Fix lusermod using a group name and not id (#61965) #77914

Merged
merged 2 commits into from
May 31, 2022
Merged

Fix lusermod using a group name and not id (#61965) #77914

merged 2 commits into from
May 31, 2022

Conversation

julien-lecomte
Copy link
Contributor

SUMMARY

Fixes #61965

lusermod will not convert group name to a group id. luseradd doesn't care if it's a group name or group id.

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

ansible.builtin.user

@ansibot ansibot added affects_2.14 bug This issue/PR relates to a bug. core_review In order to be merged, this PR must follow the core review workflow. module This issue/PR relates to a module. needs_triage Needs a first human triage before being processed. new_contributor This PR is the first contribution by a new community member. support:core This issue/PR relates to code supported by the Ansible Engineering Team. labels May 25, 2022
@mattclay mattclay removed the needs_triage Needs a first human triage before being processed. label May 26, 2022
@mattclay
Copy link
Member

Can you add integration tests to check this behavior?

@ansibot ansibot added needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. core_review In order to be merged, this PR must follow the core review workflow. and removed core_review In order to be merged, this PR must follow the core review workflow. needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR. labels May 27, 2022
@julien-lecomte julien-lecomte changed the title Fix lusermod using a group name and not id (#61965) Draft: Fix lusermod using a group name and not id (#61965) May 27, 2022
@julien-lecomte
Copy link
Contributor Author

I had a hard time running ansible-test correctly. I figured out I had to set systemd.unified_cgroup_hierarchy=0 as a kernel boot parameter to not have a docker failure.

Anyway, with the additional test I added, I encountered a second bug. luseradd does not necessarily support -N.

@julien-lecomte julien-lecomte changed the title Draft: Fix lusermod using a group name and not id (#61965) Fix lusermod using a group name and not id (#61965) May 27, 2022
@bcoca bcoca merged commit 33beeac into ansible:devel May 31, 2022
@ansible ansible locked and limited conversation to collaborators Jun 7, 2022
@julien-lecomte julien-lecomte deleted the fix-61965 branch June 22, 2022 16:53
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
affects_2.14 bug This issue/PR relates to a bug. core_review In order to be merged, this PR must follow the core review workflow. has_issue module This issue/PR relates to a module. new_contributor This PR is the first contribution by a new community member. support:core This issue/PR relates to code supported by the Ansible Engineering Team.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

user module fails to change primary group
4 participants