mirror of
https://github.com/ansible/awx.git
synced 2026-05-13 20:37:39 -02:30
surface dry_run option for system jobs through the API
This commit is contained in:
@@ -1914,6 +1914,8 @@ class RunSystemJob(BaseTask):
|
||||
json_vars = json.loads(system_job.extra_vars)
|
||||
if 'days' in json_vars and system_job.job_type != 'cleanup_facts':
|
||||
args.extend(['--days', str(json_vars.get('days', 60))])
|
||||
if 'dry_run' in json_vars and json_vars['dry_run'] and system_job.job_type != 'cleanup_facts':
|
||||
args.extend(['--dry-run'])
|
||||
if system_job.job_type == 'cleanup_jobs':
|
||||
args.extend(['--jobs', '--project-updates', '--inventory-updates',
|
||||
'--management-jobs', '--ad-hoc-commands', '--workflow-jobs',
|
||||
|
||||
Reference in New Issue
Block a user