The problem: When running ‘docker-compose up -d’ here docker starts downloading and building stuff, which uses lots of disk space and exceeds more than 4GB. As a result this build procedure stops because there is no space left.
On my home machine, the whole installation doesn’t get bigger than 1GB, but on the server the /var/lib/docker/vfs folder takes up this whole space.
Before running ‘docker-compose’ there is about 40-50% free space.
Does anyone know, where this different behaviour comes from?
Is there a way to get this fixed?
Or does docker and this project really need such a lot of space and I cannot get it working with just a 10GB server?
It is high likely a mix of low resources and an inefficient storage driver.
VFS is not a union filesystem and it does not support copy-on-write. Furthermore, it is not recommended in production (or in general):
You might want to try to enable one of the other storage drivers. Additionally, you might want to build the images on a different host, push them to a registry and just fetch the image on your vps.
You could also try if a container runtime like the balena engine is a better fit for such a low resource system.
Sorry for the late response, took me some time to figure things out.
Unfortunately, all other storage-driver are not supported on that machine. It seems I can only use “vfs”.
Apart from that I found out that on my local machine docker inflates the folder “overlay2” from 2GB up to 11GB when running ‘docker-compose up -d’.
I don’t know if this is normal behavour or if can change anything to reduce the size?
So it seems it does not work with this free server at all.
I will see if I find the time to give balea a try.