From 24759f566c179f73e09fe4d64a92e7882d2e1f89 Mon Sep 17 00:00:00 2001 From: James Cammarata Date: Thu, 13 Feb 2014 12:12:08 -0600 Subject: [PATCH] Adding 'validate_certs' option to EC2 modules When disabled, the boto connection will be instantiated without validating the SSL certificate from the target endpoint. This allows the modules to connect to Eucalyptus instances running with self-signed certs without errors. Fixes #3978 --- cloud/cloudformation | 8 ++++++++ cloud/ec2 | 9 ++++++++- cloud/ec2_ami | 8 ++++++++ cloud/ec2_eip | 9 +++++++++ cloud/ec2_elb | 8 ++++++++ cloud/ec2_elb_lb | 8 ++++++++ cloud/ec2_group | 8 ++++++++ cloud/ec2_key | 8 ++++++++ cloud/ec2_tag | 9 +++++++++ cloud/ec2_vol | 9 +++++++++ cloud/ec2_vpc | 9 +++++++++ 11 files changed, 92 insertions(+), 1 deletion(-) diff --git a/cloud/cloudformation b/cloud/cloudformation index e072f3923f8..606458b3f3c 100644 --- a/cloud/cloudformation +++ b/cloud/cloudformation @@ -88,6 +88,14 @@ options: required: false aliases: ['aws_region', 'ec2_region'] version_added: "1.5" + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" requirements: [ "boto" ] author: James S. Martin diff --git a/cloud/ec2 b/cloud/ec2 index 1b22496c8eb..e590b40fbdc 100644 --- a/cloud/ec2 +++ b/cloud/ec2 @@ -212,7 +212,14 @@ options: required: false default: null aliases: [] - + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" requirements: [ "boto" ] author: Seth Vidal, Tim Gerla, Lester Wade diff --git a/cloud/ec2_ami b/cloud/ec2_ami index a6e449cbce9..ae2eca4fa4e 100644 --- a/cloud/ec2_ami +++ b/cloud/ec2_ami @@ -101,6 +101,14 @@ options: required: false default: null aliases: [] + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" requirements: [ "boto" ] author: Evan Duffield diff --git a/cloud/ec2_eip b/cloud/ec2_eip index ab6056ae4ad..de041f42227 100644 --- a/cloud/ec2_eip +++ b/cloud/ec2_eip @@ -53,6 +53,15 @@ options: required: false default: false version_added: "1.4" + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" + requirements: [ "boto" ] author: Lorin Hochstein notes: diff --git a/cloud/ec2_elb b/cloud/ec2_elb index 1927d6c3a7a..c6f4a72b0e1 100644 --- a/cloud/ec2_elb +++ b/cloud/ec2_elb @@ -74,6 +74,14 @@ options: required: false default: yes choices: [ "yes", "no" ] + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" """ diff --git a/cloud/ec2_elb_lb b/cloud/ec2_elb_lb index 5e4db144c87..f7d23631bc0 100644 --- a/cloud/ec2_elb_lb +++ b/cloud/ec2_elb_lb @@ -73,6 +73,14 @@ options: - The AWS region to use. If not specified then the value of the EC2_REGION environment variable, if any, is used. required: false aliases: ['aws_region', 'ec2_region'] + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" """ diff --git a/cloud/ec2_group b/cloud/ec2_group index 552f6a503e0..34d9b161244 100644 --- a/cloud/ec2_group +++ b/cloud/ec2_group @@ -57,6 +57,14 @@ options: required: false default: 'present' aliases: [] + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" requirements: [ "boto" ] ''' diff --git a/cloud/ec2_key b/cloud/ec2_key index e3bcbec50c7..5e6950d2c8b 100644 --- a/cloud/ec2_key +++ b/cloud/ec2_key @@ -48,6 +48,14 @@ options: required: false default: 'present' aliases: [] + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" requirements: [ "boto" ] author: Vincent Viallet diff --git a/cloud/ec2_tag b/cloud/ec2_tag index 1bdcd404f57..ca5a337646f 100644 --- a/cloud/ec2_tag +++ b/cloud/ec2_tag @@ -59,6 +59,15 @@ options: required: false default: null aliases: [] + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" + requirements: [ "boto" ] author: Lester Wade ''' diff --git a/cloud/ec2_vol b/cloud/ec2_vol index 815460f5e65..bdd2eae3822 100644 --- a/cloud/ec2_vol +++ b/cloud/ec2_vol @@ -82,6 +82,15 @@ options: - snapshot ID on which to base the volume required: false default: null + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" + requirements: [ "boto" ] author: Lester Wade ''' diff --git a/cloud/ec2_vpc b/cloud/ec2_vpc index d50bed4bcba..7671e6314fa 100644 --- a/cloud/ec2_vpc +++ b/cloud/ec2_vpc @@ -99,6 +99,15 @@ options: required: false default: None aliases: ['ec2_access_key', 'access_key' ] + validate_certs: + description: + - When set to "no", SSL certificates will not be validated for boto versions >= 2.6.0. + required: false + default: "yes" + choices: ["yes", "no"] + aliases: [] + version_added: "1.5" + requirements: [ "boto" ] author: Carson Gee '''