input file for AWX moving code from core to AWX

Hi Team,

Currently I am working on a Role which deploys a VM from template, does a lot of configuration inside VM, installs and configures 8 different agents, format newly added disks etc. For all this there is an input yml file. All works well with Ansible core.

Every time a VM is requested a new input file is populated. When the playbook is executed it asks for a path where the input file is stored on the ansible server.

Down the line there is a plan to move to AWX or Ansible Tower.

My question is how I can use this input file when moved to AWX.
With Survey can I provide a path where the file is copied on the host?
If not, what can be done?
I have too many variables to create a survey for.

Thanks
Abhi

You could have a string parameter on a survey which you could then use as a path in a playbook but remember that AWX uses execution environments so your code will be running in a container.
That being said, you can expose paths from the server to the container via the setting “Paths to expose to isolated jobs”.
You could also “host” the yaml files on another server somewhere and use the string provided by the survey to download the yaml file.

-The AWX Team