From 45012ea723369bd08f3dae19c785848bc83e64b2 Mon Sep 17 00:00:00 2001 From: Lars Kellogg-Stedman Date: Thu, 22 Oct 2015 15:22:50 -0400 Subject: [PATCH] allow empty description attribute for os_security_group The `os_security_group` module would fail if there was no `description:` attribute: localhost | FAILED! => { "changed": false, "failed": true, "msg": "Error creating security group larstest: Invalid input for description. Reason: 'None' is not a valid string." } This commit makes the default description `''` rather than `None`. --- lib/ansible/modules/cloud/openstack/os_security_group.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/cloud/openstack/os_security_group.py b/lib/ansible/modules/cloud/openstack/os_security_group.py index 524e0ce3625..478c86e9eeb 100644 --- a/lib/ansible/modules/cloud/openstack/os_security_group.py +++ b/lib/ansible/modules/cloud/openstack/os_security_group.py @@ -90,7 +90,7 @@ def _system_state_change(module, secgroup): def main(): argument_spec = openstack_full_argument_spec( name=dict(required=True), - description=dict(default=None), + description=dict(default=''), state=dict(default='present', choices=['absent', 'present']), )