[systemd-devel] systemd-nspawn -- bind multiple directories
arnaud gaboury
arnaud.gaboury at gmail.com
Mon Apr 27 06:54:36 PDT 2015
On Mon, Apr 27, 2015 at 3:44 PM, Lennart Poettering
<lennart at poettering.net> wrote:
> On Mon, 27.04.15 10:19, arnaud gaboury (arnaud.gaboury at gmail.com) wrote:
>
>> To install a Fedora container from the raw image in my host Archlinux,
>> I can do this:
>>
>> # systemd-nspawn -M Fedora-Cloud-Base-22_Beta-20150415.x86_64.raw --
>> bind=/var/lib/machines/enl:/mnt
>>
>> Now for the use of two btrfs subvol, I would like to bind
>> /var/lib/machines/enl/{etc,var}
>>
>> Does the systemd bind options accept multi directories to bind?
>> Soemthing like this :
>>
>> # systemd-nspawn -M Fedora-Cloud-Base-22_Beta-20150415.x86_64.raw --
>> bind=/var/lib/machines/enl:/mnt /var/lib/machines/enl/etc:/mnt/etc
>> /var/lib/machines/enl/var:/mnt/var
>
> You can specify --bind= multiple times in one command line to bind
> mount multiple directories. I have updated the man page now to
> explicit mention this.
>
> The command line you are using for is hence:
>
> # systemd-nspawn -M Fedora-Cloud-Base-22_Beta-20150415.x86_64.raw --bind=/var/lib/machines/enl:/mnt --bind=/var/lib/machines/enl/etc:/mnt/etc --bind=/var/lib/machines/enl/var:/mnt/var
Very good.
Thank you for the hard job
>
> Lennart
>
> --
> Lennart Poettering, Red Hat
--
google.com/+arnaudgabourygabx
More information about the systemd-devel
mailing list