Bug 1780325
| Summary: | No error message on user adding in a group which does not exists | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 8 | Reporter: | Kaleem <ksiddiqu> |
| Component: | ansible-freeipa | Assignee: | Thomas Woerner <twoerner> |
| Status: | CLOSED ERRATA | QA Contact: | ipa-qe <ipa-qe> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 8.1 | CC: | mvarun, ndehadra |
| Target Milestone: | rc | Flags: | pm-rhel:
mirror+
|
| Target Release: | 8.0 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | ansible-freeipa-0.1.8-1.el8 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2020-04-28 16:01:56 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Kaleem
2019-12-05 17:15:04 UTC
This has already been fixed with the ipauser extension https://github.com/freeipa/ansible-freeipa/commit/40713e71f96568cbebec44bf034dc72f90f46cd2 It is part of ansible-freeipa-0.1.7+. (In reply to Thomas Woerner from comment #3) > This has already been fixed with the ipauser extension > https://github.com/freeipa/ansible-freeipa/commit/ > 40713e71f96568cbebec44bf034dc72f90f46cd2 > It is part of ansible-freeipa-0.1.7+. This has been fixed in the ipagroup rework: https://github.com/freeipa/ansible-freeipa/commit/c5e0b1b4532261dd41604cc6320d18de2ac07217 Verified
ansible-freeipa-0.1.8-1.el8.noarch
[root@master ~]# ipa user-find | grep User
User login: admin
[root@master ~]# ipa group-show testgroup01
Group name: testgroup01
GID: 1994600001
cat add_nonexisting_member_to_the_group.yaml
---
- name: Playbook to handle group member
hosts: ipaserver
become: true
tasks:
# add non-existent group member
- ipagroup:
ipaadmin_password: <xxxxxxx>
name: testgroup01
action: member
user: notestuser01
# ansible-playbook -vv -i inventory/server.hosts add_nonexisting_member_to_the_group.yaml
ansible-playbook 2.9.4
config file = /etc/ansible/ansible.cfg
configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python3.6/site-packages/ansible
executable location = /usr/bin/ansible-playbook
python version = 3.6.8 (default, Dec 5 2019, 15:45:45) [GCC 8.3.1 20191121 (Red Hat 8.3.1-5)]
Using /etc/ansible/ansible.cfg as config file
PLAYBOOK: add_nonexisting_member_to_the_group.yaml *******************************************************************
1 plays in add_nonexisting_member_to_the_group.yaml
PLAY [Playbook to handle group member] *******************************************************************************
TASK [Gathering Facts] ***********************************************************************************************
task path: /root/add_nonexisting_member_to_the_group.yaml:2
ok: [master.ipadomain.test]
META: ran handlers
TASK [ipagroup] ******************************************************************************************************
task path: /root/add_nonexisting_member_to_the_group.yaml:8
fatal: [master.ipadomain.test]: FAILED! => {"changed": false, "msg": "group_add_member: user notestuser01: no such entry"}
PLAY RECAP ***********************************************************************************************************
master.ipadomain.test : ok=1 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
Now, the error message appears while adding non-existing user members to the group.
Based on the test result, marking the bug VERIFIED
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2020:1705 |