I have created a playbook to config the awx platform using the awx.awx collection. I have the tower_cli.cfg in my home directory and I have input environment of the host, username, and password. Below is the playbook I have attempted to run.
- hosts: localhost
connection: local
gather_facts: false
collections:
- awx.awx
tasks:
- name: Create Inventory
awx.awx.inventory:
name: "test"
organization: "AWX_Admins"
#controller_config_file: "{{ ansible_config_file }}"
validate_certs: false
state: present
register: inventory
failed_when: inventory.rc != 0
The Error I receive is
/collections/ansible_collections/awx/awx/plugins/module_utils/controller_api.py", line 154
endpoint = hostname_prefix + f"{api_path}v2{endpoint}"
^
SyntaxError: invalid syntax
fatal: [localhost]: FAILED! =>
msg: Unexpected failure during module execution.
stdout: ''"