From b7972478ff656bc6fa1cc909b617b02b0dfb28b7 Mon Sep 17 00:00:00 2001 From: "Chris St. Pierre" Date: Tue, 10 Mar 2015 21:27:45 -0500 Subject: [PATCH] Update help messages for default security group commands The secgroup-{add,delete,list}-default-rules? family of commands has confusing help text that makes it sounds like they actually operate on the default security group (that is, the security group named 'default' which is the default for the current tenant). Instead, the operate on a sort of meta-security-group object which is only used to populate the 'default' security group in newly-created tenants. This is crazy confusing. These commands get fancy new help strings that should hopefully make it a little more clear. Closes-Bug: 1430354 Change-Id: I4d9569ba7ea9ad7a20e984df7a137c99240a9748 --- novaclient/v2/shell.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/novaclient/v2/shell.py b/novaclient/v2/shell.py index f030e768a..01dd4ac8d 100644 --- a/novaclient/v2/shell.py +++ b/novaclient/v2/shell.py @@ -4326,7 +4326,9 @@ def do_server_group_list(cs, args): def do_secgroup_list_default_rules(cs, args): - """List rules for the default security group.""" + """List rules that will be added to the 'default' security group for + new tenants. + """ _print_secgroup_rules(cs.security_group_default_rules.list(), show_source_group=False) @@ -4345,7 +4347,9 @@ def do_secgroup_list_default_rules(cs, args): help=_('Port at end of range.')) @cliutils.arg('cidr', metavar='', help=_('CIDR for address range.')) def do_secgroup_add_default_rule(cs, args): - """Add a rule to the default security group.""" + """Add a rule to the set of rules that will be added to the 'default' + security group for new tenants. + """ rule = cs.security_group_default_rules.create(args.ip_proto, args.from_port, args.to_port, @@ -4367,7 +4371,9 @@ def do_secgroup_add_default_rule(cs, args): help=_('Port at end of range.')) @cliutils.arg('cidr', metavar='', help=_('CIDR for address range.')) def do_secgroup_delete_default_rule(cs, args): - """Delete a rule from the default security group.""" + """Delete a rule from the set of rules that will be added to the + 'default' security group for new tenants. + """ for rule in cs.security_group_default_rules.list(): if (rule.ip_protocol and rule.ip_protocol.upper() == args.ip_proto.upper() and