[pkg-eucalyptus-commits] [SCM] managing cloud instances for Eucalyptus branch, master, updated. 3.0.0-alpha3-257-g1da8e3a

Garrett Holmstrom gholms at fedoraproject.org
Sun Jun 16 02:31:10 UTC 2013


The following commit has been merged in the master branch:
commit b3d2597e7c47ed2ef4802a216fea4dd8e99d10e3
Author: Garrett Holmstrom <gholms at fedoraproject.org>
Date:   Fri Apr 26 12:23:02 2013 -0700

    Set the default authorize rule target correctly
    
    Fixes TOOLS-313

diff --git a/euca2ools/commands/euca/modgroup.py b/euca2ools/commands/euca/modgroup.py
index 4d25d88..222bdc3 100644
--- a/euca2ools/commands/euca/modgroup.py
+++ b/euca2ools/commands/euca/modgroup.py
@@ -162,9 +162,10 @@ class ModifySecurityGroupRequest(EucalyptusRequest):
         self.params['IpPermissions.1.FromPort'] = from_port
         self.params['IpPermissions.1.ToPort']   = to_port
 
-        if not self.args.get('IpPermissions.1.IpRanges.1.GroupName'):
-            self.args.setdefault('IpPermissions.1.IpRanges.1.CidrIp',
-                                 '0.0.0.0/0')
+        if (not self.args.get('IpPermissions.1.IpRanges.1.GroupName') and
+            not self.args.get('IpPermissions.1.IpRanges.1.CidrIp')):
+            # Default rule target is the entire Internet
+            self.params['IpPermissions.1.IpRanges.1.CidrIp'] = '0.0.0.0/0'
         if (self.params.get('IpPermissions.1.Groups.1.GroupName') and
             not self.args.get('IpPermissions.1.Groups.1.UserId')):
             raise ArgumentError('argument -u is required when -o names a '

-- 
managing cloud instances for Eucalyptus



More information about the pkg-eucalyptus-commits mailing list