AWX: 24.6.1
Ansible: 2.18.5
I’m stuck trying to run my playbook in AWX. My issues is that the same project, playbook, inventory, EE works with ansible-navigator, but not in AWX.
Tasks with delegate_to: localhost
work in AWX. But not those using connection: httpapi
Successful with ansible-navigator
#ansible-navigator run dev-provision-nodes.yml -i inventories/dev/inventory.ini -vvvv --start-at-task "Set hostname" --limit cp-gw1 --execution-environment-image ee --mode stdout --pull-policy missing --container-options='--user=0'
ansible-playbook [core 2.18.5]
config file = None
configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/local/lib/python3.13/site-packages/ansible
ansible collection location = /root/.ansible/collections:/usr/share/ansible/collections
executable location = /usr/local/bin/ansible-playbook
python version = 3.13.3 (main, Apr 22 2025, 00:00:00) [GCC 14.2.1 20250110 (Red Hat 14.2.1-7)] (/usr/bin/python3)
jinja version = 3.1.6
libyaml = True
No config file found; using defaults
setting up inventory plugins
Loading collection ansible.builtin from
host_list declined parsing /home/user/ansible/inventories/dev/inventory.ini as it did not pass its verify_file() method
script declined parsing /home/user/ansible/inventories/dev/inventory.ini as it did not pass its verify_file() method
auto declined parsing /home/user/ansible/inventories/dev/inventory.ini as it did not pass its verify_file() method
yaml declined parsing /home/user/ansible/inventories/dev/inventory.ini as it did not pass its verify_file() method
Parsed /home/user/ansible/inventories/dev/inventory.ini inventory source with ini plugin
Loading collection community.vmware from /usr/share/ansible/collections/ansible_collections/community/vmware
[DEPRECATION WARNING]: community.vmware.vcenter_folder has been deprecated. Use
vmware.vmware.folder instead. This feature will be removed from
community.vmware in version 7.0.0. Deprecation warnings can be disabled by
setting deprecation_warnings=False in ansible.cfg.
Loading collection check_point.gaia from /usr/share/ansible/collections/ansible_collections/check_point/gaia
Read vars_file 'inventories/dev/credentials.yml'
Read vars_file 'inventories/dev/credentials.yml'
Loading callback plugin default of type stdout, v2.0 from /usr/local/lib/python3.13/site-packages/ansible/plugins/callback/default.py
Loading callback plugin awx_display of type stdout, v2.0 from /runner/artifacts/8e0cae0e-82d3-4b45-ab08-508f29445f88/callback/awx_display.py
Skipping callback 'awx_display', as we already have a stdout callback.
Skipping callback 'default', as we already have a stdout callback.
Skipping callback 'minimal', as we already have a stdout callback.
Skipping callback 'oneline', as we already have a stdout callback.
PLAYBOOK: dev-provision-nodes.yml **********************************************
Positional arguments: /home/user/ansible/dev-provision-nodes.yml
verbosity: 4
connection: ssh
become_method: sudo
tags: ('all',)
inventory: ('/home/user/ansible/inventories/dev/inventory.ini',)
subset: cp-gw1
forks: 5
start_at_task: Set hostname
1 plays in /home/user/ansible/dev-provision-nodes.yml
Read vars_file 'inventories/dev/credentials.yml'
Read vars_file 'inventories/dev/credentials.yml'
Read vars_file 'inventories/dev/credentials.yml'
PLAY [Provision test Checkpoint nodes] *****************************************
Read vars_file 'inventories/dev/credentials.yml'
TASK [Set hostname] ************************************************************
task path: /home/user/ansible/dev-provision-nodes.yml:86
redirecting (type: connection) ansible.builtin.httpapi to ansible.netcommon.httpapi
Loading collection ansible.netcommon from /usr/share/ansible/collections/ansible_collections/ansible/netcommon
Loading collection ansible.utils from /usr/share/ansible/collections/ansible_collections/ansible/utils
setting up inventory plugins
host_list declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
script declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
auto declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
yaml declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
ini declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
toml declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
[WARNING]: No inventory was parsed, only implicit localhost is available
<192.168.1.161> attempting to start connection
<192.168.1.161> using connection plugin ansible.netcommon.httpapi
<192.168.1.161> local domain socket does not exist, starting it
<192.168.1.161> control socket path is /root/.ansible/pc/d73657d531
<192.168.1.161> Loading collection ansible.builtin from
<192.168.1.161> redirecting (type: connection) ansible.builtin.httpapi to ansible.netcommon.httpapi
<192.168.1.161> Loading collection ansible.netcommon from /usr/share/ansible/collections/ansible_collections/ansible/netcommon
<192.168.1.161> Loading collection ansible.utils from /usr/share/ansible/collections/ansible_collections/ansible/utils
<192.168.1.161> Loading collection check_point.gaia from /usr/share/ansible/collections/ansible_collections/check_point/gaia
<192.168.1.161> setting up inventory plugins
<192.168.1.161> host_list declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
<192.168.1.161> Skipping due to inventory source not existing or not being readable by the current user
<192.168.1.161> script declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
<192.168.1.161> auto declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
<192.168.1.161> Skipping due to inventory source not existing or not being readable by the current user
<192.168.1.161> yaml declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
<192.168.1.161> Skipping due to inventory source not existing or not being readable by the current user
<192.168.1.161> ini declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
<192.168.1.161> Skipping due to inventory source not existing or not being readable by the current user
<192.168.1.161> toml declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
<192.168.1.161> local domain socket listeners started successfully
<192.168.1.161> loaded API plugin ansible_collections.check_point.gaia.plugins.httpapi.checkpoint from path /usr/share/ansible/collections/ansible_collections/check_point/gaia/plugins/httpapi/checkpoint.py for platform type check_point.gaia.checkpoint
<192.168.1.161> Loading collection ansible.builtin from
<192.168.1.161> local domain socket path is /root/.ansible/pc/d73657d531
<192.168.1.161> ESTABLISH LOCAL CONNECTION FOR USER: root
<192.168.1.161> EXEC /bin/sh -c '( umask 77 && mkdir -p "` echo /root/.ansible/tmp/ansible-local-158z6cnk36 `"&& mkdir "` echo /root/.ansible/tmp/ansible-local-158z6cnk36/ansible-tmp-1747226180.160288-18-189148207900247 `" && echo ansible-tmp-1747226180.160288-18-189148207900247="` echo /root/.ansible/tmp/ansible-local-158z6cnk36/ansible-tmp-1747226180.160288-18-189148207900247 `" ) && sleep 0'
Using module file /usr/share/ansible/collections/ansible_collections/check_point/gaia/plugins/modules/cp_gaia_hostname.py
<192.168.1.161> PUT /root/.ansible/tmp/ansible-local-158z6cnk36/tmpwy1qrebz TO /root/.ansible/tmp/ansible-local-158z6cnk36/ansible-tmp-1747226180.160288-18-189148207900247/AnsiballZ_cp_gaia_hostname.py
<192.168.1.161> EXEC /bin/sh -c 'chmod u+x /root/.ansible/tmp/ansible-local-158z6cnk36/ansible-tmp-1747226180.160288-18-189148207900247/ /root/.ansible/tmp/ansible-local-158z6cnk36/ansible-tmp-1747226180.160288-18-189148207900247/AnsiballZ_cp_gaia_hostname.py && sleep 0'
<192.168.1.161> EXEC /bin/sh -c '/usr/bin/python3 /root/.ansible/tmp/ansible-local-158z6cnk36/ansible-tmp-1747226180.160288-18-189148207900247/AnsiballZ_cp_gaia_hostname.py && sleep 0'
<192.168.1.161> EXEC /bin/sh -c 'rm -f -r /root/.ansible/tmp/ansible-local-158z6cnk36/ansible-tmp-1747226180.160288-18-189148207900247/ > /dev/null 2>&1 && sleep 0'
ok: [cp-gw1] => {
"changed": false,
"hostname": {
"name": "cp-gw1"
},
"invocation": {
"module_args": {
"name": "cp-gw1",
"version": null,
"virtual_system_id": null
}
}
}
PLAY RECAP *********************************************************************
cp-gw1 : ok=2 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
Fail in AWX:
PLAYBOOK: dev-provision-nodes.yml **********************************************
Positional arguments: ansible/dev-provision-nodes.yml
verbosity: 4
remote_user: root
connection: ssh
become_method: sudo
tags: ('test2',)
diff: True
inventory: ('/runner/inventory/hosts',)
extra_vars: ('@/runner/env/extravars',)
ask_vault_pass: True
forks: 5
1 plays in ansible/dev-provision-nodes.yml
[WARNING]: Could not match supplied host pattern, ignoring: template
Read vars_file 'inventories/dev/credentials.yml'
Read vars_file 'inventories/dev/credentials.yml'
Read vars_file 'inventories/dev/credentials.yml'
PLAY [Provision test Checkpoint nodes] *****************************************
Read vars_file 'inventories/dev/credentials.yml'
TASK [Print all hosts] *********************************************************
task path: /runner/project/ansible/dev-provision-nodes.yml:10
ok: [cp-gw1] => {
"msg": "play_hosts=['cp-gw1']"
}
Read vars_file 'inventories/dev/credentials.yml'
TASK [Set hostname] ************************************************************
task path: /runner/project/ansible/dev-provision-nodes.yml:87
redirecting (type: connection) ansible.builtin.httpapi to ansible.netcommon.httpapi
Loading collection ansible.netcommon from /usr/share/ansible/collections/ansible_collections/ansible/netcommon
Loading collection ansible.utils from /usr/share/ansible/collections/ansible_collections/ansible/utils
setting up inventory plugins
host_list declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
script declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
auto declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
yaml declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
ini declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
Skipping due to inventory source not existing or not being readable by the current user
toml declined parsing /etc/ansible/hosts as it did not pass its verify_file() method
fatal: [cp-gw1]: FAILED! => {
"msg": "No inventory was parsed, please check your configuration and options."
}
PLAY RECAP *********************************************************************
cp-gw1 : ok=1 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
EE spec:
---
version: 3
images:
base_image:
name: quay.io/fedora/fedora:41
dependencies:
ansible_core:
package_pip: ansible-core==2.18.5
ansible_runner:
package_pip: ansible-runner
system:
- openssh-clients
- sshpass
- less
galaxy:
collections:
- name: ansible.posix
version: 1.6.2
- name: ansible.utils
version: 5.1.2
- name: ansible.netcommon
version: 7.2.0
- name: check_point.mgmt
version: 6.4.0
- name: check_point.gaia
version: 7.0.0
- name: vmware.vmware
version: 2.0.0
- name: community.vmware
version: 5.6.0
additional_build_steps:
prepend_base:
- RUN dnf upgrade -y && dnf install -y python3 python3-pip python3-libdnf5 python3-wheel python3-devel libssh-devel gcc && dnf clean all && rm -rf /var/lib/apt/lists/*
All help is appreciated.