A containerless project should not require lxc to be installed

Bug #1714307 reported by David Ames
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mojo: Continuous Delivery for Juju
Confirmed
Medium
Unassigned

Bug Description

With a containerless project lxc should never get called and not have to be installed.

sudo: lxc-ls: command not found
2017-08-31 16:42:44 [ERROR] Error calling external process
Traceback (most recent call last):
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/cli.py", line 622, in run_with_args
    args.func(args)
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/utils.py", line 305, in wrapped
    return method(*args, **kwargs)
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/cli.py", line 340, in run_from_manifest
    project = mojo.project.Project(project_name, args.series, args.mojo_root)
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/project.py", line 107, in __init__
    self.container = container_class(self.name, self.series)
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/contain.py", line 408, in __init__
    Container.__init__(self, name, series, ensure_exists)
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/contain.py", line 82, in __init__
    if self.defined:
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/contain.py", line 713, in defined
    return self.check_state()
  File "/home/ubuntu/bot-control/tools/mojo-openstack/.tox/mojo/local/lib/python2.7/site-packages/mojo/contain.py", line 572, in check_state
    containers = subprocess.check_output(cmd).split()
  File "/usr/lib/python2.7/subprocess.py", line 574, in check_output
    raise CalledProcessError(retcode, cmd, output=output)
CalledProcessError: Command '('sudo', 'lxc-ls', '-1')' returned non-zero exit status 1

Revision history for this message
Tom Haddon (mthaddon) wrote :

I agree we shouldn't fail if it's not installed, but we will have to try calling it to see what projects have been created, and then just move on if not available.

Changed in mojo:
status: New → Confirmed
importance: Undecided → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.