You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Role fails when run in check mode on ansible 2.16+
Expected Behavior
When I run the playbook in check mode all the roles should function correctly and check things without creating resources
Steps to Reproduce the Bug
I have deployed/run the NGINX config Ansible role using the following playbook.yml...
- role: nginxinc.nginx
become: true
vars:
nginx_type: "opensource"
nginx_manage_repo: false
nginx_branch: stable
nginx_setup_license: false
nginx_modules:
- geoip
nginx_logrorate_conf_enable: true
# configure nginx using the official nginx role
- role: nginxinc.nginx_config
become: true
vars:
nginx_config_start: true
nginx_config_debug_output: true
# don't try to upload TLS certificates, that's handled by cert-manager
nginx_config_upload_ssl_enable: false
nginx_config_cleanup: false
nginx_config_cleanup_paths:
- directory:
- /etc/nginx/conf.d
recurse: false
nginx_config_cleanup_files:
- /etc/nginx/conf.d/default.conf
# replace the default config file with one from the template
nginx_config_main_template_enable: true
# could be www-data
nginx_config_user: www-data
# the rest of the config is irrelevant since the error is not related to the configuration of nginx
I have seen the following error(s) on my terminal/logs...
TASK [nginxinc.nginx : Verify that you are using a supported Jinja2 version on your Ansible host] ****************************************************************************************
task path: /home/redacted/.ansible/roles/nginxinc.nginx/tasks/validate/validate.yml:19
Thursday 03 April 2025 14:27:28 +1300 (0:00:00.188) 0:51:45.577 ********
Thursday 03 April 2025 14:27:28 +1300 (0:00:00.188) 0:51:45.575 ********
fatal: [redacted -> localhost]: FAILED! => {
"msg": "Unexpected templating type error occurred on (Jinja2 {{ jinja2_version['stdout'] | regex_search('jinja version = ([\\\\d.]+)', '\\\\1') | first }} is supported.): 'NoneType' object is not iterable. 'NoneType' object is not iterable"
}
Environment Details
Target deployment platforms: [e.g. AWS/GCP/local cluster/etc...] AWS EC2 accessed via a bastion host
Uh oh!
There was an error while loading. Please reload this page.
Bug Overview
Role fails when run in check mode on ansible 2.16+
Expected Behavior
When I run the playbook in check mode all the roles should function correctly and check things without creating resources
Steps to Reproduce the Bug
playbook.yml
...Environment Details
version: 0.25.0
version: 0.7.1
Additional Context
Connection is from Localhost -> SSH Bastion host -> Target instance
and
The text was updated successfully, but these errors were encountered: