Sign inSign up

maximsmol/libguestfs

By maximsmol

Updated almost 2 years ago

`libguestfs` with tools based on Alpine

Image
Developer tools
0

393

maximsmol/libguestfs repository overview

libguestfs in Docker

libguestfs and its tools in a minimal Alpine-based Docker image. Usable in Mac OS.

Source code on GitHub.

Usage

The target VM image needs to be mounted into the container.

Example wrapper scripts are provided.

Interactive guestfish Session

docker run \
  --interactive \
  --tty \
  --privileged `# for QEMU KVM` \
  --mount "type=bind,source=${dir},target=/mnt" \
  maximsmol/libguestfs:latest \
  guestfish \
    --rw \
    --add "/mnt/${base}" \
    --inspector

Running a Command

docker run \
  --privileged `# for QEMU KVM` \
  --mount "type=bind,source=${dir},target=/mnt" \
  --mount "type=bind,source=${src},target=/src/${src_base}" \
  maximsmol/libguestfs:latest \
  guestfish \
    --rw \
    --add "/mnt/${base}" \
    --inspector \
<<EOF
  copy-in "/src/${src_base}" "${dst}"
  umount-all
EOF

Tag summary

Content type

Image

Digest

sha256:5bc1b0fd0

Size

258 MB

Last updated

almost 2 years ago

docker pull maximsmol/libguestfs