mirror of
https://github.com/ansible/awx.git
synced 2026-03-03 01:38:50 -03:30
fixed validate-modules sanity tests
This commit is contained in:
committed by
Seth Foster
parent
d2d511f596
commit
535bbfcc39
@@ -360,10 +360,10 @@ def main():
|
|||||||
project=dict(),
|
project=dict(),
|
||||||
ssh_key_data=dict(no_log=True),
|
ssh_key_data=dict(no_log=True),
|
||||||
ssh_key_unlock=dict(no_log=True),
|
ssh_key_unlock=dict(no_log=True),
|
||||||
authorize=dict(type='bool'),
|
authorize=dict(type='bool', default=False),
|
||||||
authorize_password=dict(no_log=True),
|
authorize_password=dict(no_log=True),
|
||||||
client=dict(),
|
client=dict(),
|
||||||
security_token=dict(),
|
security_token=dict(no_log=True),
|
||||||
secret=dict(no_log=True),
|
secret=dict(no_log=True),
|
||||||
subscription=dict(),
|
subscription=dict(),
|
||||||
tenant=dict(),
|
tenant=dict(),
|
||||||
|
|||||||
@@ -112,6 +112,18 @@ except ImportError:
|
|||||||
def main():
|
def main():
|
||||||
argument_spec = dict(
|
argument_spec = dict(
|
||||||
all=dict(type='bool', default=False),
|
all=dict(type='bool', default=False),
|
||||||
|
credential_types=dict(type='str'),
|
||||||
|
credentials=dict(type='str'),
|
||||||
|
execution_environments=dict(type='str'),
|
||||||
|
inventory=dict(type='str'),
|
||||||
|
inventory_sources=dict(type='str'),
|
||||||
|
job_templates=dict(type='str'),
|
||||||
|
notification_templates=dict(type='str'),
|
||||||
|
organizations=dict(type='str'),
|
||||||
|
projects=dict(type='str'),
|
||||||
|
teams=dict(type='str'),
|
||||||
|
users=dict(type='str'),
|
||||||
|
workflow_job_templates=dict(type='str'),
|
||||||
)
|
)
|
||||||
|
|
||||||
# We are not going to raise an error here because the __init__ method of ControllerAWXKitModule will do that for us
|
# We are not going to raise an error here because the __init__ method of ControllerAWXKitModule will do that for us
|
||||||
|
|||||||
@@ -58,6 +58,7 @@ options:
|
|||||||
- List of exact-match Instances that will be assigned to this group
|
- List of exact-match Instances that will be assigned to this group
|
||||||
required: False
|
required: False
|
||||||
type: list
|
type: list
|
||||||
|
elements: str
|
||||||
pod_spec_override:
|
pod_spec_override:
|
||||||
description:
|
description:
|
||||||
- A custom Kubernetes or OpenShift Pod specification.
|
- A custom Kubernetes or OpenShift Pod specification.
|
||||||
@@ -68,6 +69,7 @@ options:
|
|||||||
- The instances associated with this instance_group
|
- The instances associated with this instance_group
|
||||||
required: False
|
required: False
|
||||||
type: list
|
type: list
|
||||||
|
elements: str
|
||||||
state:
|
state:
|
||||||
description:
|
description:
|
||||||
- Desired state of the resource.
|
- Desired state of the resource.
|
||||||
@@ -89,12 +91,12 @@ def main():
|
|||||||
name=dict(required=True),
|
name=dict(required=True),
|
||||||
new_name=dict(),
|
new_name=dict(),
|
||||||
credential=dict(),
|
credential=dict(),
|
||||||
is_container_group=dict(type='bool', default=False),
|
is_container_group=dict(type='bool', default=None),
|
||||||
policy_instance_percentage=dict(type='int', default='0'),
|
policy_instance_percentage=dict(type='int', default='0'),
|
||||||
policy_instance_minimum=dict(type='int', default='0'),
|
policy_instance_minimum=dict(type='int', default='0'),
|
||||||
policy_instance_list=dict(type='list'),
|
policy_instance_list=dict(type='list', elements='str'),
|
||||||
pod_spec_override=dict(),
|
pod_spec_override=dict(),
|
||||||
instances=dict(required=False, type="list", default=None),
|
instances=dict(required=False, type="list", elements='str', default=None),
|
||||||
state=dict(choices=['present', 'absent'], default='present'),
|
state=dict(choices=['present', 'absent'], default='present'),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -164,7 +164,7 @@ def main():
|
|||||||
skip_tags=dict(type='list', elements='str'),
|
skip_tags=dict(type='list', elements='str'),
|
||||||
verbosity=dict(type='int', choices=[0, 1, 2, 3, 4, 5]),
|
verbosity=dict(type='int', choices=[0, 1, 2, 3, 4, 5]),
|
||||||
diff_mode=dict(type='bool'),
|
diff_mode=dict(type='bool'),
|
||||||
credential_passwords=dict(type='dict'),
|
credential_passwords=dict(type='dict', no_log=True),
|
||||||
wait=dict(default=False, type='bool'),
|
wait=dict(default=False, type='bool'),
|
||||||
interval=dict(default=1.0, type='float'),
|
interval=dict(default=1.0, type='float'),
|
||||||
timeout=dict(default=None, type='int'),
|
timeout=dict(default=None, type='int'),
|
||||||
|
|||||||
@@ -388,24 +388,24 @@ def main():
|
|||||||
skip_tags=dict(),
|
skip_tags=dict(),
|
||||||
start_at_task=dict(),
|
start_at_task=dict(),
|
||||||
timeout=dict(type='int', default=0),
|
timeout=dict(type='int', default=0),
|
||||||
use_fact_cache=dict(type='bool', aliases=['fact_caching_enabled']),
|
use_fact_cache=dict(type='bool', aliases=['fact_caching_enabled'], default=False),
|
||||||
host_config_key=dict(),
|
host_config_key=dict(no_log=True),
|
||||||
ask_diff_mode_on_launch=dict(type='bool', aliases=['ask_diff_mode']),
|
ask_diff_mode_on_launch=dict(type='bool', aliases=['ask_diff_mode'], default=False),
|
||||||
ask_variables_on_launch=dict(type='bool', aliases=['ask_extra_vars']),
|
ask_variables_on_launch=dict(type='bool', aliases=['ask_extra_vars'], default=False),
|
||||||
ask_limit_on_launch=dict(type='bool', aliases=['ask_limit']),
|
ask_limit_on_launch=dict(type='bool', aliases=['ask_limit'], default=False),
|
||||||
ask_tags_on_launch=dict(type='bool', aliases=['ask_tags']),
|
ask_tags_on_launch=dict(type='bool', aliases=['ask_tags'], default=False),
|
||||||
ask_skip_tags_on_launch=dict(type='bool', aliases=['ask_skip_tags']),
|
ask_skip_tags_on_launch=dict(type='bool', aliases=['ask_skip_tags'], default=False),
|
||||||
ask_job_type_on_launch=dict(type='bool', aliases=['ask_job_type']),
|
ask_job_type_on_launch=dict(type='bool', aliases=['ask_job_type'], default=False),
|
||||||
ask_verbosity_on_launch=dict(type='bool', aliases=['ask_verbosity']),
|
ask_verbosity_on_launch=dict(type='bool', aliases=['ask_verbosity'], default=False),
|
||||||
ask_inventory_on_launch=dict(type='bool', aliases=['ask_inventory']),
|
ask_inventory_on_launch=dict(type='bool', aliases=['ask_inventory'], default=False),
|
||||||
ask_credential_on_launch=dict(type='bool', aliases=['ask_credential']),
|
ask_credential_on_launch=dict(type='bool', aliases=['ask_credential'], default=False),
|
||||||
survey_enabled=dict(type='bool'),
|
survey_enabled=dict(type='bool', default=False),
|
||||||
survey_spec=dict(type="dict"),
|
survey_spec=dict(type="dict"),
|
||||||
become_enabled=dict(type='bool'),
|
become_enabled=dict(type='bool', default=False),
|
||||||
diff_mode=dict(type='bool', aliases=['diff_mode_enabled']),
|
diff_mode=dict(type='bool', aliases=['diff_mode_enabled'], default=False),
|
||||||
allow_simultaneous=dict(type='bool', aliases=['concurrent_jobs_enabled']),
|
allow_simultaneous=dict(type='bool', aliases=['concurrent_jobs_enabled'], default=False),
|
||||||
scm_branch=dict(),
|
scm_branch=dict(),
|
||||||
ask_scm_branch_on_launch=dict(type='bool'),
|
ask_scm_branch_on_launch=dict(type='bool', default=False),
|
||||||
job_slice_count=dict(type='int', default='1'),
|
job_slice_count=dict(type='int', default='1'),
|
||||||
webhook_service=dict(choices=['github', 'gitlab', '']),
|
webhook_service=dict(choices=['github', 'gitlab', '']),
|
||||||
webhook_credential=dict(),
|
webhook_credential=dict(),
|
||||||
|
|||||||
@@ -29,7 +29,6 @@ options:
|
|||||||
description:
|
description:
|
||||||
- By default, the license manifest will only be applied if Tower is currently
|
- By default, the license manifest will only be applied if Tower is currently
|
||||||
unlicensed or trial licensed. When force=true, the license is always applied.
|
unlicensed or trial licensed. When force=true, the license is always applied.
|
||||||
required: True
|
|
||||||
type: bool
|
type: bool
|
||||||
default: 'False'
|
default: 'False'
|
||||||
extends_documentation_fragment: awx.awx.auth
|
extends_documentation_fragment: awx.awx.auth
|
||||||
@@ -52,7 +51,8 @@ def main():
|
|||||||
module = ControllerAPIModule(
|
module = ControllerAPIModule(
|
||||||
argument_spec=dict(
|
argument_spec=dict(
|
||||||
manifest=dict(type='str', required=True),
|
manifest=dict(type='str', required=True),
|
||||||
force=dict(type='bool', required=False),
|
eula_accepted=dict(type='bool', required=True),
|
||||||
|
force=dict(type='bool', default=False),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -136,7 +136,7 @@ def main():
|
|||||||
description=dict(),
|
description=dict(),
|
||||||
application=dict(),
|
application=dict(),
|
||||||
scope=dict(choices=['read', 'write'], default='write'),
|
scope=dict(choices=['read', 'write'], default='write'),
|
||||||
existing_token=dict(type='dict'),
|
existing_token=dict(type='dict', no_log=True),
|
||||||
existing_token_id=dict(),
|
existing_token_id=dict(),
|
||||||
state=dict(choices=['present', 'absent'], default='present'),
|
state=dict(choices=['present', 'absent'], default='present'),
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -148,6 +148,7 @@ options:
|
|||||||
description:
|
description:
|
||||||
- A json list of nodes and their coresponding options. The following suboptions describe a single node.
|
- A json list of nodes and their coresponding options. The following suboptions describe a single node.
|
||||||
type: list
|
type: list
|
||||||
|
elements: dict
|
||||||
suboptions:
|
suboptions:
|
||||||
extra_data:
|
extra_data:
|
||||||
description:
|
description:
|
||||||
|
|||||||
@@ -255,7 +255,7 @@ def main():
|
|||||||
required_if = [
|
required_if = [
|
||||||
['state', 'absent', ['identifier']],
|
['state', 'absent', ['identifier']],
|
||||||
['state', 'present', ['identifier']],
|
['state', 'present', ['identifier']],
|
||||||
['state', 'present', ['unified_job_template', 'approval_node', 'success_nodes', 'always_nodes', 'failure_nodes'], 'true'],
|
['state', 'present', ['unified_job_template', 'approval_node', 'success_nodes', 'always_nodes', 'failure_nodes'], True],
|
||||||
]
|
]
|
||||||
|
|
||||||
# Create a module for ourselves
|
# Create a module for ourselves
|
||||||
|
|||||||
Reference in New Issue
Block a user