On Fri, Jan 16, 2015 at 10:29:41AM +0100, Michael Adam wrote:
> On 2015-01-15 at 18:30 -0500, Stéphane Graber wrote:
> > On Fri, Jan 16, 2015 at 12:28:01AM +0100, Michael Adam wrote:
> > > Hi,
> > > 
> > > How are the images that lxc-download uses created?
> > > It would be great to have these recipes in the tree.
> > > 
> > > I am asking because apparently the fedora and debian
> > > jessie images don't have the improvements/fixes for
> > > running systemd as init that are installed when
> > > using the lxc-debian or lxc-fedora template to
> > > create the container (lxc.kmsg = 0 and lxc.autodev = 1).
> > > 
> > 
> > They are built using the standard templates on
> > jenkins.linuxcontainers.org using the scripts at github.com/lxc/lxc-ci.
> 
> Thanks! I am still in the process of really understanding what
> happens there. It seems that these call the regular lxc-foobar
> templates. But apparently, the download template creates the
> config for the downloaded image, essentially including the
> common config for the given distribution.
> 
> The problem here is that this does not take into account the
> special configuration needed for e.g. Debian Jessie and
> Fedora 15+ in order to make systemd happy. The debian and
> fedora templates have customizations for the generated config
> for this, but the common config is not conditional.
> This means that the mentioned containers created by lxc-download
> are not usable as is for me, but need some config changes first.
> 
> How can we circumvent that problem? Without replicating the logic
> from the other templates inside the download template?
> I generally see two thinkable approaches:
> 
> - have the creation mechanism package the config generated by
>   the distri template and have the lxc-download template
>   use that (possibly with slight modifications) instead the
>   self-generated one.
> 
> - have version-specific default/common configs shipped instead
>   of only distri-specific and have lxc-download use these.
> 
> Is there something else we can do?
> 
> Thanks - Michael

We're currently busy working on getting LXC to work properly with
systemd by default for both privileged and unprivileged containers.

The reason why I never liked the conditional config options as are
implemented today in some of the templates and why I didn't replicate
that for lxc-download is that I want people to be able to upgrade their
containers.

That's why we're working on reworking lxc.autodev and init system
detection within LXC so that you never need to set any of those options
to begin with and then can dist-upgrade from a sysvinit version of your
container to a systemd version of your container or from usptart to
systemd and things will just work.


That work is currently all that's separating us from current git master
and LXC 1.1.

-- 
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com

Attachment: signature.asc
Description: Digital signature

_______________________________________________
lxc-devel mailing list
lxc-devel@lists.linuxcontainers.org
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to