Question about Job templates access roles teams

Hi I have some questions about template access configuration.

I have created a group of users. Those users need to create/edit job templates.
to create a template, they copy (with the copy button) a base template, and they edit the new template.

but the problem is, access roles are not copied automatically so they add the access role team, manually.

Every users of the group need to have access to those templates.
they are “normal user”.

Is there a configuration to avoid to add access role manually every time we copy a job template ?

Is there a way to copy automatically the access roles ?

if its not, how can I add an access role team to a template with the REST API ?
Or any workaround ?

Thanks you

Hi,

One way around this might be to create a job template that the users have permission to launch. This job template run a playbook that will use the awx.awx collection to create a new job template and associated roles for that user. You could make use of the job_template module “copy_from” field so that you can copy from another existing job template. So then anytime a user needs a new job template, instead of hitting copy in the UI, they simply launch this job that will create a new job template for them.

If the generated templates need special fields like limits, the user could provide these details via extra_vars or a survey, and the ansible playbook can use those to fine tune the generated job template with these extra details.

Let me know if this makes sense, happy to provide more details around this

AWX Team

Hello,
I have tried, it works,

Thank you