snapcraft in docker container fails

Marco Ceppi marco.ceppi at
Wed Mar 22 12:01:28 UTC 2017

Hi Alistair,

We had a similar issue in our project, we found this:

docker run -it -v $PWD:/root/snap -w /root/snap -e SNAPCRAFT_SETUP_CORE=1
snapcraft/xenial-amd64 /bin/bash

Where, when using that flag, the core snap will already be installed.

Marco Ceppi

On Wed, Mar 22, 2017 at 5:03 AM Alistair Grant <akgrant0710 at>

> Hi All,
> I've been building snap packages within a docker container successfully.
> Up to now all the containers have been built with devmode, but I would
> now like to build one with classic confinement (for a development
> application).
> Building the package fails because the core snap isn't installed,
> attempting to install the core package results in:
> root at 2bd7fd92945f:/# snap install core
> 2017/03/22 08:36:31.602176 main.go:220: WARNING: cannot create syslog
> logger
> 2017/03/22 08:36:31.604709 api.go:890: Installing snap "core" revision
> unset
> error: cannot perform the following tasks:
> - Mount snap "core" (1441) ([daemon-reload] failed with exit status 1:
> Failed to connect to bus: No such file or directory
> )
> I understand that I'm trying to push docker past its intended usage
> (syslog, dbus, etc), but does anyone have a workaround for this?
> Thanks very much,
> Alistair
> --
> Snapcraft mailing list
> Snapcraft at
> Modify settings or unsubscribe at:

More information about the Snapcraft mailing list