Skip to content
docker-to-linux - make bootable linux disk image abusing docker
Branch: master
Clone or download
Latest commit 4420903 Jun 16, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
alpine initial Jun 2, 2019
debian initial Jun 2, 2019
ubuntu add ubuntu builder Jun 10, 2019
.gitignore initial Jun 2, 2019
Dockerfile initial Jun 2, 2019
Makefile add ubuntu builder Jun 10, 2019
README.md Update README.md Jun 15, 2019
create_image.sh initial Jun 2, 2019
partition.txt initial Jun 2, 2019

README.md

docker-to-linux - make bootable linux disk image abusing docker

There is no real goal behind this project. Just out of my curiosity what if:

  • launch a base Linux container (debian, alpine, etc)
  • pull in Linux kernel & init system (systemd, OpenRC, etc)
  • dump container's filesystem to a disk image
  • install bootloader (syslinux) to this image...

Then it should be probably possible to launch a real virtual machine with such an image!

Try it out:

make debian
qemu-system-x86_64 -drive file=linux.img,index=0,media=disk,format=raw
make clean

make alpine
qemu-system-x86_64 -drive file=linux.img,index=0,media=disk,format=raw
make clean

It works!

Check out Makefile for more details or read my article on iximiuz.com.

You can’t perform that action at this time.