Sanity fixes in various modules (#50080)

This commit is contained in:
Dag Wieers
2018-12-18 16:53:46 +01:00
committed by Adam Miller
parent 6caed0c38b
commit 15d39f9108
23 changed files with 372 additions and 340 deletions

View File

@@ -20,7 +20,7 @@ ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['preview'],
'supported_by': 'community'}
DOCUMENTATION = '''
DOCUMENTATION = r'''
---
module: ce_aaa_server
version_added: "2.4"
@@ -33,51 +33,62 @@ options:
state:
description:
- Specify desired state of the resource.
type: str
choices: [ absent, present ]
default: present
choices: ['present', 'absent']
authen_scheme_name:
description:
- Name of an authentication scheme.
The value is a string of 1 to 32 characters.
type: str
first_authen_mode:
description:
- Preferred authentication mode.
type: str
choices: ['invalid', 'local', 'hwtacacs', 'radius', 'none']
author_scheme_name:
description:
- Name of an authorization scheme.
The value is a string of 1 to 32 characters.
type: str
first_author_mode:
description:
- Preferred authorization mode.
type: str
choices: ['invalid', 'local', 'hwtacacs', 'if-authenticated', 'none']
acct_scheme_name:
description:
- Accounting scheme name.
The value is a string of 1 to 32 characters.
type: str
accounting_mode:
description:
- Accounting Mode.
type: str
choices: ['invalid', 'hwtacacs', 'radius', 'none']
domain_name:
description:
- Name of a domain.
The value is a string of 1 to 64 characters.
type: str
radius_server_group:
description:
- RADIUS server group's name.
The value is a string of 1 to 32 case-insensitive characters.
type: str
hwtacas_template:
description:
- Name of a HWTACACS template.
The value is a string of 1 to 32 case-insensitive characters.
type: str
local_user_group:
description:
- Name of the user group where the user belongs. The user inherits all the rights of the user group.
The value is a string of 1 to 32 characters.
type: str
'''
EXAMPLES = '''
EXAMPLES = r'''
- name: AAA server test
hosts: cloudengine

View File

@@ -1,7 +1,8 @@
#!/usr/bin/python
#
# (c) 2015 Peter Sprygada, <psprygada@ansible.com>
# Copyright (c) 2017 Dell Inc.
# -*- coding: utf-8 -*-
# Copyright: (c) 2015, Peter Sprygada <psprygada@ansible.com>
# Copyright: (c) 2017, Dell Inc.
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
@@ -35,6 +36,7 @@ options:
is returned. If the I(wait_for) argument is provided, the
module is not returned until the condition is satisfied or
the number of retries has expired.
type: list
required: true
wait_for:
description:
@@ -43,6 +45,7 @@ options:
before moving forward. If the conditional is not true
within the configured number of I(retries), the task fails.
See examples.
type: list
version_added: "2.2"
match:
description:
@@ -52,8 +55,9 @@ options:
then all conditionals in the wait_for must be satisfied. If
the value is set to C(any) then only one of the values must be
satisfied.
type: str
default: all
choices: ['any', 'all']
choices: [ all, any ]
version_added: "2.5"
retries:
description:
@@ -61,6 +65,7 @@ options:
before it is considered failed. The command is run on the
target device every retry and evaluated against the
I(wait_for) conditions.
type: int
default: 10
interval:
description:
@@ -68,6 +73,7 @@ options:
of the command. If the command does not pass the specified
conditions, the interval indicates how long to wait before
trying the command again.
type: int
default: 1
"""

View File

@@ -1,7 +1,8 @@
#!/usr/bin/python
#
# (c) 2015 Peter Sprygada, <psprygada@ansible.com>
# Copyright (c) 2016 Dell Inc.
# -*- coding: utf-8 -*-
# Copyright: (c) 2015, Peter Sprygada <psprygada@ansible.com>
# Copyright: (c) 2016, Dell Inc.
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
@@ -34,6 +35,7 @@ options:
is returned. If the I(wait_for) argument is provided, the
module is not returned until the condition is satisfied or
the number of retries has expired.
type: list
required: true
wait_for:
description:
@@ -42,6 +44,7 @@ options:
before moving forward. If the conditional is not true
within the configured number of I(retries), the task fails.
See examples.
type: list
version_added: "2.2"
match:
description:
@@ -51,8 +54,9 @@ options:
then all conditionals in the wait_for must be satisfied. If
the value is set to C(any) then only one of the values must be
satisfied.
type: str
default: all
choices: ['any', 'all']
choices: [ all, any ]
version_added: "2.5"
retries:
description:
@@ -60,6 +64,7 @@ options:
before it is considered failed. The command is run on the
target device every retry and evaluated against the
I(wait_for) conditions.
type: int
default: 10
interval:
description:
@@ -67,6 +72,7 @@ options:
of the command. If the command does not pass the specified
conditions, the interval indicates how long to wait before
trying the command again.
type: int
default: 1
"""

View File

@@ -1,9 +1,11 @@
#!/usr/bin/python
#
# (c) 2015 Peter Sprygada, <psprygada@ansible.com>
# Copyright (c) 2016 Dell Inc.
# -*- coding: utf-8 -*-
# Copyright: (c) 2015, Peter Sprygada <psprygada@ansible.com>
# Copyright: (c) 2016, Dell Inc.
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import absolute_import, division, print_function
__metaclass__ = type
@@ -34,6 +36,7 @@ options:
is returned. If the I(wait_for) argument is provided, the
module is not returned until the condition is satisfied or
the number of retries has expired.
type: list
required: true
wait_for:
description:
@@ -42,6 +45,7 @@ options:
before moving forward. If the conditional is not true
within the configured number of I(retries), the task fails.
See examples.
type: list
version_added: "2.2"
match:
description:
@@ -51,8 +55,9 @@ options:
then all conditionals in the wait_for must be satisfied. If
the value is set to C(any) then only one of the values must be
satisfied.
type: str
default: all
choices: ['any', 'all']
choices: [ all, any ]
version_added: "2.5"
retries:
description:
@@ -60,6 +65,7 @@ options:
before it is considered failed. The command is run on the
target device every retry and evaluated against the
I(wait_for) conditions.
type: int
default: 10
interval:
description:
@@ -67,6 +73,7 @@ options:
of the command. If the command does not pass the specified
conditions, the interval indicates how long to wait before
trying the command again.
type: int
default: 1
notes: