ansible-playbook 2.9.27 config file = None configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules'] ansible python module location = /usr/local/lib/python3.9/site-packages/ansible executable location = /usr/local/bin/ansible-playbook python version = 3.9.19 (main, May 16 2024, 11:40:09) [GCC 8.5.0 20210514 (Red Hat 8.5.0-22)] No config file found; using defaults [WARNING]: running playbook inside collection fedora.linux_system_roles Skipping callback 'actionable', as we already have a stdout callback. Skipping callback 'counter_enabled', as we already have a stdout callback. Skipping callback 'debug', as we already have a stdout callback. Skipping callback 'dense', as we already have a stdout callback. Skipping callback 'dense', as we already have a stdout callback. Skipping callback 'full_skip', as we already have a stdout callback. Skipping callback 'json', as we already have a stdout callback. Skipping callback 'minimal', as we already have a stdout callback. Skipping callback 'null', as we already have a stdout callback. Skipping callback 'oneline', as we already have a stdout callback. Skipping callback 'selective', as we already have a stdout callback. Skipping callback 'skippy', as we already have a stdout callback. Skipping callback 'stderr', as we already have a stdout callback. Skipping callback 'unixy', as we already have a stdout callback. Skipping callback 'yaml', as we already have a stdout callback. PLAYBOOK: tests_default.yml **************************************************** 1 plays in /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/tests/sudo/tests_default.yml PLAY [Ensure that the role runs with default parameters] *********************** META: ran handlers TASK [Test setup] ************************************************************** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/tests/sudo/tests_default.yml:9 Thursday 22 August 2024 11:05:26 -0400 (0:00:00.026) 0:00:00.026 ******* included: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/tests/sudo/tasks/setup.yml for managed_node1 TASK [Create temp test directory] ********************************************** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/tests/sudo/tasks/setup.yml:3 Thursday 22 August 2024 11:05:26 -0400 (0:00:00.035) 0:00:00.061 ******* changed: [managed_node1] => { "ansible_facts": { "discovered_interpreter_python": "/usr/libexec/platform-python" }, "changed": true, "gid": 0, "group": "root", "mode": "0700", "owner": "root", "path": "/var/tmp/sudo_05qngs20", "secontext": "unconfined_u:object_r:user_tmp_t:s0", "size": 6, "state": "directory", "uid": 0 } TASK [Backup sudoers] ********************************************************** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/tests/sudo/tasks/setup.yml:10 Thursday 22 August 2024 11:05:26 -0400 (0:00:00.509) 0:00:00.571 ******* changed: [managed_node1] => { "changed": true, "checksum": "e683ad5e5d8d7112d14924c11c98be7bf2ef4918", "dest": "/var/tmp/sudo_05qngs20/sudoers", "gid": 0, "group": "root", "md5sum": "1b134d95a4618029ff962a63b021e1ca", "mode": "0644", "owner": "root", "secontext": "system_u:object_r:etc_t:s0", "size": 4328, "src": "/etc/sudoers", "state": "file", "uid": 0 } TASK [Backup sudoers.d] ******************************************************** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/tests/sudo/tasks/setup.yml:19 Thursday 22 August 2024 11:05:27 -0400 (0:00:00.466) 0:00:01.037 ******* changed: [managed_node1] => { "changed": true, "checksum": null, "dest": "/var/tmp/sudo_05qngs20/sudoers.d", "gid": 0, "group": "root", "md5sum": null, "mode": "0644", "owner": "root", "secontext": "unconfined_u:object_r:user_tmp_t:s0", "size": 23, "src": "/etc/sudoers.d", "state": "directory", "uid": 0 } TASK [Run the role] ************************************************************ task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/tests/sudo/tests_default.yml:12 Thursday 22 August 2024 11:05:27 -0400 (0:00:00.377) 0:00:01.414 ******* TASK [fedora.linux_system_roles.sudo : Set version specific variables] ********* task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/main.yml:2 Thursday 22 August 2024 11:05:27 -0400 (0:00:00.029) 0:00:01.444 ******* included: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/set_vars.yml for managed_node1 TASK [fedora.linux_system_roles.sudo : Ensure ansible_facts used by role] ****** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/set_vars.yml:2 Thursday 22 August 2024 11:05:27 -0400 (0:00:00.020) 0:00:01.465 ******* ok: [managed_node1] TASK [fedora.linux_system_roles.sudo : Check if system is ostree] ************** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/set_vars.yml:10 Thursday 22 August 2024 11:05:28 -0400 (0:00:00.664) 0:00:02.130 ******* ok: [managed_node1] => { "changed": false, "stat": { "exists": false } } TASK [fedora.linux_system_roles.sudo : Set flag to indicate system is ostree] *** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/set_vars.yml:15 Thursday 22 August 2024 11:05:28 -0400 (0:00:00.437) 0:00:02.567 ******* ok: [managed_node1] => { "ansible_facts": { "__sudo_is_ostree": false }, "changed": false } TASK [fedora.linux_system_roles.sudo : Check if transactional-update exists in /sbin] *** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/set_vars.yml:22 Thursday 22 August 2024 11:05:28 -0400 (0:00:00.034) 0:00:02.601 ******* ok: [managed_node1] => { "changed": false, "stat": { "exists": false } } TASK [fedora.linux_system_roles.sudo : Set flag if transactional-update exists] *** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/set_vars.yml:27 Thursday 22 August 2024 11:05:29 -0400 (0:00:00.331) 0:00:02.932 ******* ok: [managed_node1] => { "ansible_facts": { "__sudo_is_transactional": false }, "changed": false } TASK [fedora.linux_system_roles.sudo : Set platform/version specific variables] *** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/set_vars.yml:31 Thursday 22 August 2024 11:05:29 -0400 (0:00:00.034) 0:00:02.967 ******* skipping: [managed_node1] => (item=RedHat.yml) => { "ansible_loop_var": "item", "changed": false, "item": "RedHat.yml", "skip_reason": "Conditional result was False" } skipping: [managed_node1] => (item=CentOS.yml) => { "ansible_loop_var": "item", "changed": false, "item": "CentOS.yml", "skip_reason": "Conditional result was False" } skipping: [managed_node1] => (item=CentOS_8.yml) => { "ansible_loop_var": "item", "changed": false, "item": "CentOS_8.yml", "skip_reason": "Conditional result was False" } skipping: [managed_node1] => (item=CentOS_8.yml) => { "ansible_loop_var": "item", "changed": false, "item": "CentOS_8.yml", "skip_reason": "Conditional result was False" } TASK [fedora.linux_system_roles.sudo : Scan sudoers] *************************** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/main.yml:5 Thursday 22 August 2024 11:05:29 -0400 (0:00:00.047) 0:00:03.015 ******* skipping: [managed_node1] => { "censored": "the output has been hidden due to the fact that 'no_log: true' was specified for this result", "changed": false } TASK [fedora.linux_system_roles.sudo : Compare] ******************************** task path: /tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/main.yml:12 Thursday 22 August 2024 11:05:29 -0400 (0:00:00.030) 0:00:03.046 ******* skipping: [managed_node1] => { "changed": false, "skip_reason": "Conditional result was False" } ERROR! The conditional check 'comparation_result | bool' failed. The error was: error while evaluating conditional (comparation_result | bool): 'comparation_result' is undefined The error appears to be in '/tmp/collections-YcE/ansible_collections/fedora/linux_system_roles/roles/sudo/tasks/main.yml': line 17, column 3, but may be elsewhere in the file depending on the exact syntax problem. The offending line appears to be: - name: Sudo is already configured ^ here