From 0f9ade7fe3e02010dc8652126e889f3cb48a79b1 Mon Sep 17 00:00:00 2001 From: Toshio Kuratomi Date: Tue, 30 Jun 2015 10:37:09 -0700 Subject: [PATCH 1/6] Fix bundler documentation --- packaging/language/bundler.py | 39 ++++++++++++++++++++++------------- 1 file changed, 25 insertions(+), 14 deletions(-) diff --git a/packaging/language/bundler.py b/packaging/language/bundler.py index 82ef2838a9a..5f605f5e947 100644 --- a/packaging/language/bundler.py +++ b/packaging/language/bundler.py @@ -40,18 +40,22 @@ options: default: present chdir: description: - - The directory to execute the bundler commands from. This directoy needs to contain a valid Gemfile or .bundle/ directory + - The directory to execute the bundler commands from. This directoy + needs to contain a valid Gemfile or .bundle/ directory required: false default: temporary working directory exclude_groups: description: - - A list of Gemfile groups to exclude during operations. This only applies when state is C(present). Bundler considers this a 'remembered' - property for the Gemfile and will automatically exclude groups in future operations even if C(exclude_groups) is not set + - A list of Gemfile groups to exclude during operations. This only + applies when state is C(present). Bundler considers this + a 'remembered' property for the Gemfile and will automatically exclude + groups in future operations even if C(exclude_groups) is not set required: false default: null clean: description: - - Only applies if state is C(present). If set removes any gems on the target host that are not in the gemfile + - Only applies if state is C(present). If set removes any gems on the + target host that are not in the gemfile required: false choices: [yes, no] default: "no" @@ -68,8 +72,9 @@ options: default: "no" deployment_mode: description: - - Only applies if state is C(present). If set it will only install gems that are in the default or production groups. Requires a Gemfile.lock - file to have been created prior + - Only applies if state is C(present). If set it will only install gems + that are in the default or production groups. Requires a Gemfile.lock + file to have been created prior required: false choices: [yes, no] default: "no" @@ -81,19 +86,25 @@ options: default: "yes" gem_path: description: - - Only applies if state is C(present). Specifies the directory to install the gems into. If C(chdir) is set then this path is relative to C(chdir) - required: false - default: RubyGems gem paths + - Only applies if state is C(present). Specifies the directory to + install the gems into. If C(chdir) is set then this path is relative to + C(chdir) + required: false + default: RubyGems gem paths binstub_directory: description: - - Only applies if state is C(present). Specifies the directory to install any gem bins files to. When executed the bin files will run within - the context of the Gemfile and fail if any required gem dependencies are not installed. If C(chdir) is set then this path is relative to C(chdir) + - Only applies if state is C(present). Specifies the directory to + install any gem bins files to. When executed the bin files will run + within the context of the Gemfile and fail if any required gem + dependencies are not installed. If C(chdir) is set then this path is + relative to C(chdir) required: false default: null extra_args: description: - - A space separated string of additional commands that can be applied to the Bundler command. Refer to the Bundler documentation for more - information + - A space separated string of additional commands that can be applied to + the Bundler command. Refer to the Bundler documentation for more + information required: false default: null author: Tim Hoiberg @@ -196,4 +207,4 @@ def main(): from ansible.module_utils.basic import * -main() \ No newline at end of file +main() From 3be267b57908d013533e8cfbbe3bc78a67da2b0f Mon Sep 17 00:00:00 2001 From: Matt Martz Date: Tue, 30 Jun 2015 13:45:12 -0500 Subject: [PATCH 2/6] Give dpkg_selections a .py file extension --- packaging/{dpkg_selections => dpkg_selections.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename packaging/{dpkg_selections => dpkg_selections.py} (100%) diff --git a/packaging/dpkg_selections b/packaging/dpkg_selections.py similarity index 100% rename from packaging/dpkg_selections rename to packaging/dpkg_selections.py From 8ba11e97e24396a32e8d8a3276f6c6e7960f2371 Mon Sep 17 00:00:00 2001 From: Matt Martz Date: Tue, 30 Jun 2015 13:45:24 -0500 Subject: [PATCH 3/6] Add missing __init__.py file --- clustering/__init__.py | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 clustering/__init__.py diff --git a/clustering/__init__.py b/clustering/__init__.py new file mode 100644 index 00000000000..e69de29bb2d From 9f9422fcb583a81d560627a90a2a503a84942ba6 Mon Sep 17 00:00:00 2001 From: Matt Martz Date: Tue, 30 Jun 2015 13:45:53 -0500 Subject: [PATCH 4/6] Update vsphere_copy.py to use new style module_utils import --- cloud/vmware/vsphere_copy.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/cloud/vmware/vsphere_copy.py b/cloud/vmware/vsphere_copy.py index 44e20caebdf..4364e8b5197 100644 --- a/cloud/vmware/vsphere_copy.py +++ b/cloud/vmware/vsphere_copy.py @@ -149,6 +149,7 @@ def main(): else: module.fail_json(msg='Failed to upload', status=resp.status, reason=resp.reason, length=resp.length, version=resp.version, headers=resp.getheaders(), chunked=resp.chunked, url=url) -# this is magic, see lib/ansible/module_common.py -#<> +# Import module snippets +from ansible.module_utils.basic import * + main() From fda25aa93b9f11a144093cc8ec7c167b0ef302ff Mon Sep 17 00:00:00 2001 From: Matt Martz Date: Tue, 30 Jun 2015 13:46:14 -0500 Subject: [PATCH 5/6] Fix interpreter line in webfaction modules --- cloud/webfaction/webfaction_app.py | 2 +- cloud/webfaction/webfaction_db.py | 2 +- cloud/webfaction/webfaction_domain.py | 2 +- cloud/webfaction/webfaction_mailbox.py | 2 +- cloud/webfaction/webfaction_site.py | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cloud/webfaction/webfaction_app.py b/cloud/webfaction/webfaction_app.py index 3e42ec1265e..3d11d17a432 100644 --- a/cloud/webfaction/webfaction_app.py +++ b/cloud/webfaction/webfaction_app.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!/usr/bin/python # # Create a Webfaction application using Ansible and the Webfaction API # diff --git a/cloud/webfaction/webfaction_db.py b/cloud/webfaction/webfaction_db.py index f420490711c..82eac1c1f42 100644 --- a/cloud/webfaction/webfaction_db.py +++ b/cloud/webfaction/webfaction_db.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!/usr/bin/python # # Create a webfaction database using Ansible and the Webfaction API # diff --git a/cloud/webfaction/webfaction_domain.py b/cloud/webfaction/webfaction_domain.py index 0b35faf110f..c809dd6beb3 100644 --- a/cloud/webfaction/webfaction_domain.py +++ b/cloud/webfaction/webfaction_domain.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!/usr/bin/python # # Create Webfaction domains and subdomains using Ansible and the Webfaction API # diff --git a/cloud/webfaction/webfaction_mailbox.py b/cloud/webfaction/webfaction_mailbox.py index 7547b6154e5..c08bd477601 100644 --- a/cloud/webfaction/webfaction_mailbox.py +++ b/cloud/webfaction/webfaction_mailbox.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!/usr/bin/python # # Create webfaction mailbox using Ansible and the Webfaction API # diff --git a/cloud/webfaction/webfaction_site.py b/cloud/webfaction/webfaction_site.py index 57eae39c0dc..bb1bfb94457 100644 --- a/cloud/webfaction/webfaction_site.py +++ b/cloud/webfaction/webfaction_site.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!/usr/bin/python # # Create Webfaction website using Ansible and the Webfaction API # From 9a36454329da8909a675e3cc555dce2acda230df Mon Sep 17 00:00:00 2001 From: Matt Martz Date: Tue, 30 Jun 2015 13:46:45 -0500 Subject: [PATCH 6/6] replace tabs with spaces in mongodb_user.py --- database/misc/mongodb_user.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/database/misc/mongodb_user.py b/database/misc/mongodb_user.py index ede8004945b..0529abdea09 100644 --- a/database/misc/mongodb_user.py +++ b/database/misc/mongodb_user.py @@ -225,10 +225,10 @@ def main(): update_password = module.params['update_password'] try: - if replica_set: - client = MongoClient(login_host, int(login_port), replicaset=replica_set, ssl=ssl) - else: - client = MongoClient(login_host, int(login_port), ssl=ssl) + if replica_set: + client = MongoClient(login_host, int(login_port), replicaset=replica_set, ssl=ssl) + else: + client = MongoClient(login_host, int(login_port), ssl=ssl) if login_user is None and login_password is None: mongocnf_creds = load_mongocnf()