'enter' was broken because we weren't correctly identifying the container
name. Strip the newline from the inspect result so that we can reliably
match against the 'running' state.
Signed-off-by: Sage Weil <sage@newdream.net>
(cherry picked from commit
fb5e4b3740241d5c41b348e0fc5f59ebde5ee558)
ctx.container_engine.path, 'container', 'inspect',
'--format', '{{.State.Status}}', name
])
- if out == 'running':
+ if out.strip() == 'running':
return name
return None