Commit 6142681d authored by Swann Perarnau's avatar Swann Perarnau Committed by Valentin Reis

[fix] have command provide a default uuid

Previous merges let the cmd send an empty container uuid, resulting in
some issues when the user doesn't provide one. Restore the previous
behavior.
parent fd393d12
...@@ -6,6 +6,7 @@ import logging ...@@ -6,6 +6,7 @@ import logging
import signal import signal
import os import os
import nrm.messaging import nrm.messaging
import uuid
RPC_MSG = nrm.messaging.MSGTYPES['up_rpc_req'] RPC_MSG = nrm.messaging.MSGTYPES['up_rpc_req']
logger = logging.getLogger('nrm') logger = logging.getLogger('nrm')
...@@ -49,7 +50,7 @@ class CommandLineInterface(object): ...@@ -49,7 +50,7 @@ class CommandLineInterface(object):
'path': argv.command, 'path': argv.command,
'args': argv.args, 'args': argv.args,
'environ': dict(environ), 'environ': dict(environ),
'container_uuid': str(argv.ucontainername), 'container_uuid': argv.ucontainername or str(uuid.uuid4()),
} }
msg = RPC_MSG['run'](**command) msg = RPC_MSG['run'](**command)
# command fsm # command fsm
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment