[Lxc-users] Automated Mount for every lxc container

Sebastian Bachmann me at free-minds.net
Wed Apr 25 19:55:55 UTC 2012


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,
We are currently migrating from openvz to lxc and now we facing a
problem which can be solved quickly but this would cause other trouble
I'm trying to prevent.
We had in all our VZ Containers a directory mounted from the host,
which contains configs and shared stuff. This is now really mandatory
for all containers, so it would be bad if we woudnt have it anymore.
we solved the problem on the OpenVZ side with a common-mount script
which gets the VZID from the config file and mounts the stuff into
/var/lib/vz/root/$VZID/shared/folder

so we need the same thing for lxc... Otherwise we would have to put in
the mount path into every lxc config file and for about 30 LXC's this
would create a mess...

I found this Post on the mailinglist:
http://www.mail-archive.com/lxc-devel@lists.sourceforge.net/msg01204.html
which says something about excactly what we would need. is this
feature allready implemented? I couldnt find anything in the man page
that it would...

with this feature we could write a common-config file which is
included into every lxc config and could work, beside one fact: how
does the common script know where to mount? Is is possible to use
variables inside the config? so is the lxc.rootfs also a variable, i
can use in my config?

thanks a lot, maybe someone has come up with a solution allready!

sebastian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBAgAGBQJPmFbLAAoJEAhgHfpCPcybyAoH/3e2Zj2GbOVxaO0OWDigBvaT
wvIPPAYqMONt5hmLZnYDZuBttHaLMcx9JWCNQB8wCaB4gS54XPoAXDvlNjiFfUN7
lZvs+PnuBl6ODvawGRjTCtQK1zzZQQmqwq5MMB/2Sk6uOz024Uk7AJrBSprAZvbQ
BcsFewEhzVNmS33vTsg3DY7/2jSYFeWJq7wZHIiSkBfoBR0XjKKxPQxSh7p82BBg
gPf1+0VGCgEU6yuMXUuLKv6Z9WZzUvNr27hSOFq+w5UHXFeihK17bpDprSjWX4xT
xITjni7Z/616l9uhzZmR5aI0WWBKz9U3C4gcY2n03SRuCOE00VciLBORofY1cYo=
=5Q1Q
-----END PGP SIGNATURE-----




More information about the lxc-users mailing list