Open ltutar opened 3 years ago
up, need to use tags too
Hi guys,
You can add this in your "src/main/resources/synthetic.xml" in the "launch.Job" task =>
<property name="job_tags" category="input" kind="string" required="false" description="The tags to run" />
Then you add this in the "src/main/jython/run_job_template.py" =>
if task_vars['jobtags']: vars = str(task_vars['job_tags']) print("* set jobtags : {0}".format(vars)) k_vars['jobtags'] = vars
In my case, it works, I can now give Ansible Tower the tags to be run.
Hope I understand your use case.
Regards,
Jeremy
Hi,
{"inventory_id":2,"credentials":[3,11],"job_type":"run","limit":"","job_tags":"levent","skip_tags":"","extra_vars":{"git_access_protocol":"https","git_clone_url":"egypt.intern/cdaas/cdaas-demo-app.git","git_project_access_name":"cdaas-demo-app","git_project_access_token":"$encrypted$","test_directory":"/tmp/cypress","git_repository_name":"cdaas-demo-app"},"scm_branch":""}
job_tags is not part extra_vars. I would like to provide the job_tags via job template task.