Add friendly event hints for logging

When creating a network log with the '--event' parameter, it is
impossible to know which parameter values can be specified, and it
is necessary to add a prompt.

Change-Id: I6aa4f95b650cdc7b04e74b851a78a2ae42fc288a
This commit is contained in:
zhanghao2 2019-07-16 22:41:52 -04:00
parent cf95be3ea5
commit 34924865b3

View file

@ -118,7 +118,7 @@ class CreateNetworkLog(command.ShowOne):
help=_('Name for the network log'))
parser.add_argument(
'--event',
metavar='<event>',
metavar='{ALL,ACCEPT,DROP}',
choices=['ALL', 'ACCEPT', 'DROP'],
type=nc_utils.convert_to_uppercase,
help=_('An event to store with log'))