mirror of
https://github.com/ansible/awx.git
synced 2026-03-21 02:47:35 -02:30
Fill in the new execution environment collection module
as well as changes to other ones that need to be able to attach EEs.
This commit is contained in:
committed by
Shane McDonald
parent
c1133b3f6d
commit
6d935f740c
@@ -31,10 +31,6 @@ options:
|
||||
description:
|
||||
- Description to use for the project.
|
||||
type: str
|
||||
execution_environment:
|
||||
description:
|
||||
- Execution Environment to use for the project.
|
||||
type: str
|
||||
scm_type:
|
||||
description:
|
||||
- Type of SCM resource.
|
||||
@@ -106,6 +102,14 @@ options:
|
||||
- Local absolute file path containing a custom Python virtualenv to use
|
||||
type: str
|
||||
default: ''
|
||||
default_environment:
|
||||
description:
|
||||
- Default Execution Environment to use for jobs relating to the project.
|
||||
type: str
|
||||
execution_environment:
|
||||
description:
|
||||
- Execution Environment to use for project updates.
|
||||
type: str
|
||||
organization:
|
||||
description:
|
||||
- Name of organization for project.
|
||||
@@ -243,6 +247,8 @@ def main():
|
||||
allow_override=dict(type='bool', aliases=['scm_allow_override']),
|
||||
timeout=dict(type='int', default=0, aliases=['job_timeout']),
|
||||
custom_virtualenv=dict(),
|
||||
default_environment=dict(),
|
||||
execution_environment=dict(),
|
||||
organization=dict(),
|
||||
notification_templates_started=dict(type="list", elements='str'),
|
||||
notification_templates_success=dict(type="list", elements='str'),
|
||||
@@ -274,6 +280,8 @@ def main():
|
||||
allow_override = module.params.get('allow_override')
|
||||
timeout = module.params.get('timeout')
|
||||
custom_virtualenv = module.params.get('custom_virtualenv')
|
||||
default_ee = module.params.get('default_environment')
|
||||
ee = module.params.get('execution_environment')
|
||||
organization = module.params.get('organization')
|
||||
state = module.params.get('state')
|
||||
wait = module.params.get('wait')
|
||||
@@ -337,6 +345,10 @@ def main():
|
||||
project_fields['description'] = description
|
||||
if credential is not None:
|
||||
project_fields['credential'] = credential
|
||||
if default_ee is not None:
|
||||
project_fields['default_environment'] = module.resolve_name_to_id('execution_environments', default_ee)
|
||||
if ee is not None:
|
||||
project_fields['execution_environment'] = module.resolve_name_to_id('execution_environments', ee)
|
||||
if allow_override is not None:
|
||||
project_fields['allow_override'] = allow_override
|
||||
if scm_type == '':
|
||||
|
||||
Reference in New Issue
Block a user