From 478691f297efbdf42aa7c198a807a0a4860b33db Mon Sep 17 00:00:00 2001 From: Thilo-Alexander Ginkel Date: Tue, 7 Jun 2016 23:03:20 +0200 Subject: [PATCH] Fix gitlab_* module boolean parameter declaration (#2385) Without these fixes using the modules would result in the following error: implementation error: unknown type requested for validate_certs --- .../modules/extras/source_control/gitlab_group.py | 2 +- .../modules/extras/source_control/gitlab_project.py | 12 ++++++------ .../modules/extras/source_control/gitlab_user.py | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/ansible/modules/extras/source_control/gitlab_group.py b/lib/ansible/modules/extras/source_control/gitlab_group.py index 1088690206..a5fa98d13f 100644 --- a/lib/ansible/modules/extras/source_control/gitlab_group.py +++ b/lib/ansible/modules/extras/source_control/gitlab_group.py @@ -146,7 +146,7 @@ def main(): module = AnsibleModule( argument_spec=dict( server_url=dict(required=True), - validate_certs=dict(required=False, default=True, type=bool, aliases=['verify_ssl']), + validate_certs=dict(required=False, default=True, type='bool', aliases=['verify_ssl']), login_user=dict(required=False, no_log=True), login_password=dict(required=False, no_log=True), login_token=dict(required=False, no_log=True), diff --git a/lib/ansible/modules/extras/source_control/gitlab_project.py b/lib/ansible/modules/extras/source_control/gitlab_project.py index 302965fce2..da21589186 100644 --- a/lib/ansible/modules/extras/source_control/gitlab_project.py +++ b/lib/ansible/modules/extras/source_control/gitlab_project.py @@ -297,7 +297,7 @@ def main(): module = AnsibleModule( argument_spec=dict( server_url=dict(required=True), - validate_certs=dict(required=False, default=True, type=bool, aliases=['verify_ssl']), + validate_certs=dict(required=False, default=True, type='bool', aliases=['verify_ssl']), login_user=dict(required=False, no_log=True), login_password=dict(required=False, no_log=True), login_token=dict(required=False, no_log=True), @@ -305,11 +305,11 @@ def main(): name=dict(required=True), path=dict(required=False), description=dict(required=False), - issues_enabled=dict(default=True, type=bool), - merge_requests_enabled=dict(default=True, type=bool), - wiki_enabled=dict(default=True, type=bool), - snippets_enabled=dict(default=True, type=bool), - public=dict(default=False, type=bool), + issues_enabled=dict(default=True, type='bool'), + merge_requests_enabled=dict(default=True, type='bool'), + wiki_enabled=dict(default=True, type='bool'), + snippets_enabled=dict(default=True, type='bool'), + public=dict(default=False, type='bool'), visibility_level=dict(default="0", choices=["0", "10", "20"]), import_url=dict(required=False), state=dict(default="present", choices=["present", 'absent']), diff --git a/lib/ansible/modules/extras/source_control/gitlab_user.py b/lib/ansible/modules/extras/source_control/gitlab_user.py index f7253db456..d9b40401b0 100644 --- a/lib/ansible/modules/extras/source_control/gitlab_user.py +++ b/lib/ansible/modules/extras/source_control/gitlab_user.py @@ -263,7 +263,7 @@ def main(): module = AnsibleModule( argument_spec=dict( server_url=dict(required=True), - validate_certs=dict(required=False, default=True, type=bool, aliases=['verify_ssl']), + validate_certs=dict(required=False, default=True, type='bool', aliases=['verify_ssl']), login_user=dict(required=False, no_log=True), login_password=dict(required=False, no_log=True), login_token=dict(required=False, no_log=True),