Bootable image in container


I want to use 2GB file as bootable image in container to launch it with my application but I also remember to optimize my Dockerfile :slight_smile:

To put in another way I would not like to copy that image each time when container is run but to keep it on my Host and use it in the container. How should I do that?

I have reviewed dozen posts here but cant find any similar use-case.

What do you mean by “bootable image”? You can’t boot an image in a container, but you can create a Docker image and start the container. Starting the container actually means starting a process isolated by the kernel using namespaces. There is no virtualization machine to “boot” an operating system for example as you would normally do in a VM.

I want to run Simics platform inside of Docker and there I am using different bootable image in .craff extension. This is what I am doing now but on Host and it was one of the reason to start learning Docker - to run multiple containers with Simics simulator inside (each of them with different bootable image). So you are saying my plan fails?

Now I understand you. Thank you for the link. So Simics is an emulator and you want to run its command in a container probably on an older Linux distribution. If you already know how to use Simics inside a container and only looking for a solution to avoid copying the Simics image into a Docker image, you can mount the Simics image into the container:

If you also need help to containerize Simics, since I know nothing about Simics, I found this

Two very usefull articles. Thank you very much for that @rimelek .