Available choices for 'state' explicitly listed.

This commit is contained in:
Quentin Stafford-Fraser 2015-05-10 20:47:31 +01:00
parent a0ef5e4a59
commit de28b84bf7
5 changed files with 5 additions and 5 deletions

View file

@ -72,7 +72,7 @@ def main():
module = AnsibleModule( module = AnsibleModule(
argument_spec = dict( argument_spec = dict(
name = dict(required=True), name = dict(required=True),
state = dict(required=False, default='present'), state = dict(required=False, choices=['present', 'absent'], default='present'),
type = dict(required=True), type = dict(required=True),
autostart = dict(required=False, choices=BOOLEANS, default=False), autostart = dict(required=False, choices=BOOLEANS, default=False),
extra_info = dict(required=False, default=""), extra_info = dict(required=False, default=""),

View file

@ -68,7 +68,7 @@ def main():
module = AnsibleModule( module = AnsibleModule(
argument_spec = dict( argument_spec = dict(
name = dict(required=True), name = dict(required=True),
state = dict(required=False, default='present'), state = dict(required=False, choices=['present', 'absent'], default='present'),
# You can specify an IP address or hostname. # You can specify an IP address or hostname.
type = dict(required=True), type = dict(required=True),
password = dict(required=False, default=None), password = dict(required=False, default=None),

View file

@ -57,7 +57,7 @@ def main():
module = AnsibleModule( module = AnsibleModule(
argument_spec = dict( argument_spec = dict(
name = dict(required=True), name = dict(required=True),
state = dict(required=False, default='present'), state = dict(required=False, choices=['present', 'absent'], default='present'),
subdomains = dict(required=False, default=[]), subdomains = dict(required=False, default=[]),
login_name = dict(required=True), login_name = dict(required=True),
login_password = dict(required=True), login_password = dict(required=True),

View file

@ -56,7 +56,7 @@ def main():
argument_spec=dict( argument_spec=dict(
mailbox_name=dict(required=True), mailbox_name=dict(required=True),
mailbox_password=dict(required=True), mailbox_password=dict(required=True),
state=dict(required=False, default='present'), state=dict(required=False, choices=['present', 'absent'], default='present'),
login_name=dict(required=True), login_name=dict(required=True),
login_password=dict(required=True), login_password=dict(required=True),
), ),

View file

@ -90,7 +90,7 @@ def main():
module = AnsibleModule( module = AnsibleModule(
argument_spec = dict( argument_spec = dict(
name = dict(required=True), name = dict(required=True),
state = dict(required=False, default='present'), state = dict(required=False, choices=['present', 'absent'], default='present'),
# You can specify an IP address or hostname. # You can specify an IP address or hostname.
host = dict(required=True), host = dict(required=True),
https = dict(required=False, choices=BOOLEANS, default=False), https = dict(required=False, choices=BOOLEANS, default=False),