Closed tetherit closed 8 years ago
virtualbox and docker are two different technologies. i use alpine as a base docker container image. docker images are intended to be lightweight process "containers" not true virtual machines. virtualbox, vmware, parallels, etc. provide virtual machines. i use this alpine virtualbox so that i have a development environment i can ssh to while creating software targeted to run in an alpine based docker container.
I understand that but the question remains how to make it smaller? - I can see for example there are a lot of redundant drivers and firmware in the vagrant version that cannot be used in VirtualBox. I wonder if there is a kernel compiled for VirtualBox. That's just one thing that will vastly reduce space consumption and not make it any less of a development environment.
I want to use docker containers for when deploying to Linux servers and just a self contained VirtualBox image for when deploying to a windows box (packaging docker and all its dependencies is less practical than just virtualbox and an image).
Is there a stripped down or minimal version of alpine for vagrant/virtualbox? -- I will look at how Docker made theirs so much smaller.
i'm sure you can remove files and packages to minimize an alpine virtual machine image. the vagrant-alpine plugin isn't tied to any specific alpine virtual machine image. the virtualbox version i use in the example is the alpine virtualbox image that i use for development. one can vagrant init
with any alpine virtual machine image, the vagrant-alpine plugin does not require use of a specific alpine image. the alpine virtualbox image i created isn't intended to be a production (space and performance) optimized image; i use docker for that purpose.
I noticed when I bring up an Alpine 3.3 VM with Docker, it takes up ~160MB in VirtualBox - when I bring up the same with vagrant-alpine with the same packages, it takes up ~340MB.
Any ideas why that is and any advice how to reduce the size?