[libvirt] [sandbox v2 00/11] Actually use host-image mounts on /

Cédric Bosdonnat cbosdonnat at suse.com
Mon Jun 29 16:44:08 UTC 2015


Hi all,

In the virt-sandbox documentation we had examples with host-image mounts
targetting /. However the / in the sandbox was still the host one. The
main goal of this patch series is to fix that problem. This will also
be needed to run docker container with libvirt-sandbox.

I also added some configure flags to disable lzma or zlib support at
build time. At least opensuse 13.2 doesn't have static lzma.

Diff to v1:
  * Fixed Dan's comments
  * Fixed the container case:
    * Made init-lxc all-static
    * Moved the init copy code to libvirt-sandbox-builder.c
  * Use setenv to set the LD_LIBRARY_PATH rather than reset the whole
    environment using execve

Cédric Bosdonnat (11):
  Allow disabling build with lzma.
  Allow disabling zlib support.
  Enable strcmp checks in libvirt-sandbox-init-qemu.c
  Make init-lxc all static
  Copy all needed init programs and all its deps to config subdir
  Remove init-common dependency on libvirt-sandbox.so
  init-qemu: extract the mounts.cfg ntry mounting code
  qemu: use mounts targeting / as root
  Add function to check if there is a mount with / target
  Don't add sandbox:root device if we have a mount targetting /
  container builder: don't expose host rootfs if unneeded

 cfg.mk                                             |   2 -
 configure.ac                                       |  37 ++++-
 libvirt-sandbox/Makefile.am                        |  45 +++---
 .../libvirt-sandbox-builder-container.c            |  37 +++--
 libvirt-sandbox/libvirt-sandbox-builder-machine.c  |  22 +--
 libvirt-sandbox/libvirt-sandbox-builder.c          | 159 ++++++++++++++++++-
 libvirt-sandbox/libvirt-sandbox-builder.h          |   2 +
 libvirt-sandbox/libvirt-sandbox-config-all.h       |  62 ++++++++
 libvirt-sandbox/libvirt-sandbox-config-disk.c      |   2 +-
 libvirt-sandbox/libvirt-sandbox-config-initrd.c    |   2 +-
 .../libvirt-sandbox-config-interactive.c           |   2 +-
 .../libvirt-sandbox-config-mount-file.c            |   2 +-
 .../libvirt-sandbox-config-mount-guest-bind.c      |   2 +-
 .../libvirt-sandbox-config-mount-host-bind.c       |   2 +-
 .../libvirt-sandbox-config-mount-host-image.c      |   2 +-
 libvirt-sandbox/libvirt-sandbox-config-mount-ram.c |   2 +-
 libvirt-sandbox/libvirt-sandbox-config-mount.c     |   2 +-
 .../libvirt-sandbox-config-network-address.c       |   2 +-
 ...rt-sandbox-config-network-filterref-parameter.c |   2 +-
 .../libvirt-sandbox-config-network-filterref.c     |   2 +-
 .../libvirt-sandbox-config-network-route.c         |   2 +-
 libvirt-sandbox/libvirt-sandbox-config-network.c   |   2 +-
 .../libvirt-sandbox-config-service-generic.c       |   2 +-
 .../libvirt-sandbox-config-service-systemd.c       |   2 +-
 libvirt-sandbox/libvirt-sandbox-config-service.c   |   2 +-
 libvirt-sandbox/libvirt-sandbox-config.c           |  23 ++-
 libvirt-sandbox/libvirt-sandbox-config.h           |   1 +
 libvirt-sandbox/libvirt-sandbox-init-common.c      |   5 +-
 libvirt-sandbox/libvirt-sandbox-init-lxc.c         |  16 +-
 libvirt-sandbox/libvirt-sandbox-init-qemu.c        | 175 +++++++++++++++++----
 libvirt-sandbox/libvirt-sandbox-util.c             |   2 +-
 libvirt-sandbox/libvirt-sandbox.sym                |   1 +
 32 files changed, 519 insertions(+), 104 deletions(-)
 create mode 100644 libvirt-sandbox/libvirt-sandbox-config-all.h

-- 
2.1.4




More information about the libvir-list mailing list