Enable the selection of subset of variables to be passed to ansible tower integration

Description:
When running an ansible tower job from the morpheus instance, a predefined stack of variables will be passed/exposed as extra_variables to the Tower Job, which will be available to use in the playbook itself.
Currently these add up to a total of more than 3000 lines of different variables. In practice we only need a selected subset of the variables within the playbook. There is no way of only passing a subset of variables to the tower job instead of the whole stack. We currently working around this problem with a python task that maps the variables as we need and only passes the needed selection, it then calls the awx tower via api and passes those variables.
We therefore recreating the usecase of the morpheus awx tower integration, which is kind of not a practical solution.
Variables that are added via custom config also just end up on top of the stack.
The custom config would be good place for this, but it isn’t possible to pass custom config when the task is integrated into a provisonal workflow.


Example/Use case(s):
When adding a ansible tower job task into a provisional workflow, we only want to pass a selected subset of variables to the playbook.
Ideally we could also map them beforehand to not rewrite all of the templates we want to use. Custom config would be the ideal place for that. I don’t know how to pass custom config when the task is inside a provisional workflow. And it isn’t possible to add it beforehand.
As example the task would look like this, when the custom config is available in the task configuration window


And in the awx tower only the configured variables would appear instead of the whole stack.


1 Like