Merge "Make --profile load from environment variables"

This commit is contained in:
Jenkins 2017-07-27 04:13:59 +00:00 committed by Gerrit Code Review
commit 790303e7b3
3 changed files with 10 additions and 1 deletions

View File

@ -289,6 +289,7 @@ You'll find complete documentation on the shell by running
match the one configured on the cinder api server.
Without key the profiling will not be triggered even
if osprofiler is enabled on server side.
Defaults to env[OS_PROFILE].
--os-auth-strategy <auth-strategy>
Authentication strategy (Env: OS_AUTH_STRATEGY,
default keystone). For now, any other value will

View File

@ -240,13 +240,15 @@ class OpenStackCinderShell(object):
if osprofiler_profiler:
parser.add_argument('--profile',
metavar='HMAC_KEY',
default=utils.env('OS_PROFILE'),
help=_('HMAC key to use for encrypting '
'context data for performance profiling '
'of operation. This key needs to match the '
'one configured on the cinder api server. '
'Without key the profiling will not be '
'triggered even if osprofiler is enabled '
'on server side.'))
'on server side. Defaults to '
'env[OS_PROFILE].'))
self._append_global_identity_args(parser)

View File

@ -0,0 +1,6 @@
---
features:
- |
``--profile`` argument can be loaded from ``OS_PROFILE``
environment variable to avoid repeating ``--profile``
in openstack commands.