Handle entrypoint is None
Change-Id: Ic6eb27cb018eec6d476fbbe17f29ac020ce83b71 Closes-Bug: #1872130
This commit is contained in:
@@ -243,7 +243,9 @@ class CreateContainer(command.ShowOne):
|
|||||||
opts['command'] = parsed_args.command
|
opts['command'] = parsed_args.command
|
||||||
opts['registry'] = parsed_args.registry
|
opts['registry'] = parsed_args.registry
|
||||||
opts['host'] = parsed_args.host
|
opts['host'] = parsed_args.host
|
||||||
opts['entrypoint'] = zun_utils.parse_entrypoint(parsed_args.entrypoint)
|
if parsed_args.entrypoint:
|
||||||
|
opts['entrypoint'] = zun_utils.parse_entrypoint(
|
||||||
|
parsed_args.entrypoint)
|
||||||
if parsed_args.security_group:
|
if parsed_args.security_group:
|
||||||
opts['security_groups'] = parsed_args.security_group
|
opts['security_groups'] = parsed_args.security_group
|
||||||
if parsed_args.expose_port:
|
if parsed_args.expose_port:
|
||||||
@@ -946,7 +948,9 @@ class RunContainer(command.ShowOne):
|
|||||||
opts['command'] = parsed_args.command
|
opts['command'] = parsed_args.command
|
||||||
opts['registry'] = parsed_args.registry
|
opts['registry'] = parsed_args.registry
|
||||||
opts['host'] = parsed_args.host
|
opts['host'] = parsed_args.host
|
||||||
opts['entrypoint'] = zun_utils.parse_entrypoint(parsed_args.entrypoint)
|
if parsed_args.entrypoint:
|
||||||
|
opts['entrypoint'] = zun_utils.parse_entrypoint(
|
||||||
|
parsed_args.entrypoint)
|
||||||
if parsed_args.security_group:
|
if parsed_args.security_group:
|
||||||
opts['security_groups'] = parsed_args.security_group
|
opts['security_groups'] = parsed_args.security_group
|
||||||
if parsed_args.expose_port:
|
if parsed_args.expose_port:
|
||||||
|
@@ -28,7 +28,6 @@ def _get_container_args(**kwargs):
|
|||||||
'mounts': [],
|
'mounts': [],
|
||||||
'nets': [],
|
'nets': [],
|
||||||
'command': [],
|
'command': [],
|
||||||
'entrypoint': [],
|
|
||||||
}
|
}
|
||||||
default_args.update(kwargs)
|
default_args.update(kwargs)
|
||||||
return default_args
|
return default_args
|
||||||
|
@@ -215,7 +215,8 @@ def do_create(cs, args):
|
|||||||
opts['command'] = args.command
|
opts['command'] = args.command
|
||||||
opts['registry'] = args.registry
|
opts['registry'] = args.registry
|
||||||
opts['host'] = args.host
|
opts['host'] = args.host
|
||||||
opts['entrypoint'] = zun_utils.parse_entrypoint(args.entrypoint)
|
if args.entrypoint:
|
||||||
|
opts['entrypoint'] = zun_utils.parse_entrypoint(args.entrypoint)
|
||||||
if args.healthcheck:
|
if args.healthcheck:
|
||||||
opts['healthcheck'] = zun_utils.parse_health(args.healthcheck)
|
opts['healthcheck'] = zun_utils.parse_health(args.healthcheck)
|
||||||
|
|
||||||
@@ -749,7 +750,8 @@ def do_run(cs, args):
|
|||||||
opts['command'] = args.command
|
opts['command'] = args.command
|
||||||
opts['registry'] = args.registry
|
opts['registry'] = args.registry
|
||||||
opts['host'] = args.host
|
opts['host'] = args.host
|
||||||
opts['entrypoint'] = zun_utils.parse_entrypoint(args.entrypoint)
|
if args.entrypoint:
|
||||||
|
opts['entrypoint'] = zun_utils.parse_entrypoint(args.entrypoint)
|
||||||
if args.healthcheck:
|
if args.healthcheck:
|
||||||
opts['healthcheck'] = zun_utils.parse_health(args.healthcheck)
|
opts['healthcheck'] = zun_utils.parse_health(args.healthcheck)
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user