Bug 2135754

Summary: [ansible-freeeipa] It should not be possible to disable SID from ipa config module, and the error message should be clear [rhel-8.7.0.z]
Product: Red Hat Enterprise Linux 8 Reporter: RHEL Program Management Team <pgm-rhel-tools>
Component: ansible-freeipaAssignee: Rafael Jeffman <rjeffman>
Status: CLOSED ERRATA QA Contact: ipa-qe <ipa-qe>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 8.8CC: ipa-qe, mjurasek, mvarun, rjeffman, twoerner
Target Milestone: rcKeywords: Regression, Triaged, ZStream
Target Release: ---Flags: pm-rhel: mirror+
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: ansible-freeipa-1.8.3-2.el8_7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 2127447 Environment:
Last Closed: 2022-11-08 11:32:08 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 2127447    
Bug Blocks:    

Comment 7 Varun Mylaraiah 2022-10-25 03:35:27 UTC
Verified

ansible-2.9.27-1.el8ae.noarch
ansible-freeipa-1.8.3-2.el8_7.noarch

Passed	ansible_freeipa_tests/config/test_config.py::TestConfigInvalid::test_enable_sid_with_no
------------------------------ Captured log call -------------------------------
INFO     pytest_multihost.host.Host.ansible.ParamikoTransport:transport.py:293 WRITE inventory/config.hosts
DEBUG    paramiko.transport.sftp:sftp.py:158 [chan 0] open(b'inventory/config.hosts', 'wb')
DEBUG    paramiko.transport.sftp:sftp.py:158 [chan 0] open(b'inventory/config.hosts', 'wb') -> 00000000
DEBUG    paramiko.transport.sftp:sftp.py:158 [chan 0] close(00000000)
INFO     pytest_multihost.host.Host.ansible.ParamikoTransport:transport.py:329 PUT config_module.yml
DEBUG    paramiko.transport.sftp:sftp.py:158 [chan 0] open(b'config_module.yml', 'wb')
DEBUG    paramiko.transport.sftp:sftp.py:158 [chan 0] open(b'config_module.yml', 'wb') -> 00000000
DEBUG    paramiko.transport.sftp:sftp.py:158 [chan 0] close(00000000)
DEBUG    paramiko.transport.sftp:sftp.py:158 [chan 0] stat(b'config_module.yml')
DEBUG    paramiko.transport:channel.py:1212 [chan 54] Max packet in: 32768 bytes
DEBUG    paramiko.transport:channel.py:1212 [chan 54] Max packet out: 32768 bytes
DEBUG    paramiko.transport:transport.py:1819 Secsh channel 54 opened.
INFO     pytest_multihost.host.Host.ansible.ParamikoTransport:transport.py:318 RUN ['ansible-playbook', '--ssh-extra-args="-o StrictHostKeyChecking=no"', '-vv', '-i', 'inventory/config.hosts', 'config_module.yml']
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:519 RUN ['ansible-playbook', '--ssh-extra-args="-o StrictHostKeyChecking=no"', '-vv', '-i', 'inventory/config.hosts', 'config_module.yml']
DEBUG    paramiko.transport:channel.py:1212 [chan 54] Sesch channel 54 request ok
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 -bash: line 1: cd: /root/multihost_tests: No such file or directory
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 -bash: line 2: /root/multihost_tests/env.sh: No such file or directory
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 ansible-playbook 2.9.27
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563   config file = /etc/ansible/ansible.cfg
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563   configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563   ansible python module location = /usr/lib/python3.6/site-packages/ansible
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563   executable location = /usr/bin/ansible-playbook
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563   python version = 3.6.8 (default, Jun 14 2022, 09:19:35) [GCC 8.5.0 20210514 (Red Hat 8.5.0-13)]
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Using /etc/ansible/ansible.cfg as config file
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'actionable', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'counter_enabled', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'debug', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'dense', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'dense', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'full_skip', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'json', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'minimal', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'null', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'oneline', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'selective', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'skippy', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'stderr', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'unixy', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 Skipping callback 'yaml', as we already have a stdout callback.
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 PLAYBOOK: config_module.yml ****************************************************
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 1 plays in config_module.yml
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 PLAY [Playbook to ensure SID disables(enable_sid no) is not possible.] *********
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 TASK [Gathering Facts] *********************************************************
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 task path: /root/config_module.yml:2
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 ok: [master.ipadomain.test]
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 META: ran handlers
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 TASK [ipaconfig] ***************************************************************
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 task path: /root/config_module.yml:6
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 fatal: [master.ipadomain.test]: FAILED! => {"changed": false, "msg": "SID cannot be disabled."}
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 PLAY RECAP *********************************************************************
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 master.ipadomain.test      : ok=1    changed=0    unreachable=0    failed=1    skipped=0    rescued=0    ignored=0   
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:563 
DEBUG    paramiko.transport:channel.py:1212 [chan 54] EOF received (54)
DEBUG    paramiko.transport:channel.py:1212 [chan 54] EOF sent (54)
DEBUG    pytest_multihost.host.Host.ansible.cmd54:transport.py:217 Exit code: 2


Based on the test result, mark the bug as Verified.

Comment 11 errata-xmlrpc 2022-11-08 11:32:08 UTC
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 (ansible-freeipa bug fix and enhancement update), 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-2022:7827