]> review.fuel-infra Code Review - openstack-build/heat-build.git/commitdiff
heat clients : Make boto client select http/https from configfile
authorSteven Hardy <shardy@redhat.com>
Fri, 8 Feb 2013 11:34:58 +0000 (11:34 +0000)
committerSteven Hardy <shardy@redhat.com>
Fri, 8 Feb 2013 11:34:58 +0000 (11:34 +0000)
Currently we hardcode is_secure=False, but boto supports configuration
of this option from the config file (either ~/.boto or /etc/boto.cfg)
so better to do that

NOTE - you will need to update your boto config to include is_secure=0
to retain current (non https) behavior, since it defaults to on

ref bug 1117594

Change-Id: Ic13e8604f12d3d5be4ec132a1bc04ae7624ec85d
Signed-off-by: Steven Hardy <shardy@redhat.com>
etc/boto.cfg
heat/cfn_client/boto_client.py

index eb911c0efc82b4fe3201aced6d28bac405224383..06ee34834b3dd5e1836a80a309f0ad2a22caa8ad 100644 (file)
@@ -11,6 +11,9 @@
 # Make boto output verbose debugging information
 debug = 0
 
+# Disable https connections
+is_secure = 0
+
 # Override the default AWS endpoint to connect to heat on localhost
 cfn_region_name = heat
 cfn_region_endpoint = 127.0.0.1
index 2914a4f9aa4290b8701645f440830a7df06475fa..03b0a5bf541be2fa6f6d727612f92f7fed3d26b6 100644 (file)
@@ -286,11 +286,9 @@ def get_client(host, port=None, username=None,
 
     # Note we pass None/None for the keys by default
     # This means boto reads /etc/boto.cfg, or ~/.boto
-    # Also note is_secure is defaulted to False as HTTPS connections
-    # don't seem to work atm, FIXME
+    # set is_secure=0 in the config to disable https
     cloudformation = BotoClient(aws_access_key_id=aws_access_key,
                                 aws_secret_access_key=aws_secret_key,
-                                is_secure=False,
                                 port=port,
                                 path="/v1")
     if cloudformation: