'Constructor.
:param cmd: The list of command arguments to invoke.
:param run_as_root: The process should run with elevated privileges.
:param respawn_interval: Optional, the interval in seconds to wait
to respawn after unexpected process death. Respawn will
only be attempted if a value of 0 or greater is provided.
:param namespace: Optional, start the command in the specified
namespace.
:param log_output: Optional, also log received output.
:param die_on_error: Optional, kills the process on stderr output.'

def __init__(self, cmd, run_as_root=False, respawn_interval=None, namespace=None, log_output=False, die_on_error=False):

    self.cmd_without_namespace = cmd
    self._cmd = ip_lib.add_namespace_to_cmd(cmd, namespace)
    self.run_as_root = run_as_root
    if ((respawn_interval is not None) and (respawn_interval < 0)):
        raise ValueError(_('respawn_interval    must    be    >=    0    if    provided.'))
    self.respawn_interval = respawn_interval
    self._process = None
    self._pid = None
    self._is_running = False
    self._kill_event = None
    self._reset_queues()
    self._watchers = []
    self.log_output = log_output
    self.die_on_error = die_on_error
