From 4f7777ca0e1451f77d6935e15f87d27a950b5de4 Mon Sep 17 00:00:00 2001 From: Dean Troyer Date: Wed, 31 Dec 2014 09:59:28 -0600 Subject: [PATCH] Command docs: ec2 credentials Add ec2 credentials docs Change-Id: I1699d1c8e9859153557081966654646966a3268d --- .../command-objects/ec2-credentials.rst | 98 +++++++++++++++++++ doc/source/commands.rst | 1 + openstackclient/identity/v2_0/ec2creds.py | 14 +-- 3 files changed, 107 insertions(+), 6 deletions(-) create mode 100644 doc/source/command-objects/ec2-credentials.rst diff --git a/doc/source/command-objects/ec2-credentials.rst b/doc/source/command-objects/ec2-credentials.rst new file mode 100644 index 0000000000..a5b6754947 --- /dev/null +++ b/doc/source/command-objects/ec2-credentials.rst @@ -0,0 +1,98 @@ +=============== +ec2 credentials +=============== + +Identity v2 + +ec2 credentials create +---------------------- + +Create EC2 credentials + +.. program:: ec2 credentials create +.. code-block:: bash + + os ec2 credentials create + [--project ] + [--user ] + +.. option:: --project + + Specify an alternate project (default: current authenticated project) + +.. option:: --user + + Specify an alternate user (default: current authenticated user) + +The :option:`--project` and :option:`--user` options are typically only +useful for admin users, but may be allowed for other users depending on +the policy of the cloud and the roles granted to the user. + +ec2 credentials delete +---------------------- + +Delete EC2 credentials + +.. program:: ec2 credentials delete +.. code-block:: bash + + os ec2 credentials delete + [--user ] + + +.. option:: --user + + Specify a user + +.. _ec2_credentials_delete-access-key: +.. describe:: access-key + + Credentials access key + +The :option:`--user` option is typically only useful for admin users, but +may be allowed for other users depending on the policy of the cloud and +the roles granted to the user. + +ec2 credentials list +-------------------- + +List EC2 credentials + +.. program:: ec2 credentials list +.. code-block:: bash + + os ec2 credentials list + [--user ] + +.. option:: --user + + Filter list by + +The :option:`--user` option is typically only useful for admin users, but +may be allowed for other users depending on the policy of the cloud and +the roles granted to the user. + +ec2 credentials show +-------------------- + +Display EC2 credentials details + +.. program:: ec2 credentials show +.. code-block:: bash + + os ec2 credentials show + [--user ] + + +.. option:: --user + + Specify a user + +.. _ec2_credentials_show-access-key: +.. describe:: access-key + + Credentials access key + +The :option:`--user` option is typically only useful for admin users, but +may be allowed for other users depending on the policy of the cloud and +the roles granted to the user. diff --git a/doc/source/commands.rst b/doc/source/commands.rst index 0040700e86..7e15053f95 100644 --- a/doc/source/commands.rst +++ b/doc/source/commands.rst @@ -80,6 +80,7 @@ referring to both Compute and Volume quotas. * ``container``: Object Store - a grouping of objects * ``credentials``: (**Identity**) specific to identity providers * ``domain``: (**Identity**) a grouping of projects +* ``ec2 cedentials``: (**Identity**) AWS EC2-compatibile credentials * ``endpoint``: (**Identity**) the base URL used to contact a specific service * ``extension``: (**Compute**, **Identity**, **Volume**) OpenStack server API extensions * ``flavor``: (**Compute**) pre-defined server configurations: ram, root disk, etc diff --git a/openstackclient/identity/v2_0/ec2creds.py b/openstackclient/identity/v2_0/ec2creds.py index a20ffd4b57..90553eb1f9 100644 --- a/openstackclient/identity/v2_0/ec2creds.py +++ b/openstackclient/identity/v2_0/ec2creds.py @@ -37,12 +37,14 @@ class CreateEC2Creds(show.ShowOne): parser.add_argument( '--project', metavar='', - help=_('Specify a project [admin only]'), + help=_('Specify an alternate project' + ' (default: current authenticated project)'), ) parser.add_argument( '--user', metavar='', - help=_('Specify a user [admin only]'), + help=_('Specify an alternate user' + ' (default: current authenticated user)'), ) return parser @@ -95,7 +97,7 @@ class DeleteEC2Creds(command.Command): parser.add_argument( '--user', metavar='', - help=_('Specify a user [admin only]'), + help=_('Specify a user'), ) return parser @@ -125,7 +127,7 @@ class ListEC2Creds(lister.Lister): parser.add_argument( '--user', metavar='', - help=_('Specify a user [admin only]'), + help=_('Specify a user'), ) return parser @@ -154,7 +156,7 @@ class ListEC2Creds(lister.Lister): class ShowEC2Creds(show.ShowOne): - """Show EC2 credentials""" + """Display EC2 credentials details""" log = logging.getLogger(__name__ + '.ShowEC2Creds') @@ -168,7 +170,7 @@ class ShowEC2Creds(show.ShowOne): parser.add_argument( '--user', metavar='', - help=_('Specify a user [admin only]'), + help=_('Specify a user'), ) return parser