Sebastian Bachmann <me@...> writes:

> 
> 
> 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-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f <at>
public.gmane.org/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
> 


Sebastian...

First I need to warn you that I'm just learning LXC myself over the last 3
months but I've found alot of good information and I think if I understand what
you are asking.. that it can be done with bind.

Look at this web page's script and search for

"#configure shared directory in containers"

https://github.com/chmouel/my-lxc-setup/blob/master/install.sh

I've seen other examples and I know I've book-marked them but this was the first
I spotted so I figured I throw it out to you to see if it helps?

Brian



------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Lxc-users mailing list
Lxc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-users

Reply via email to