A new way of servicing docker images (Feb 2022)

Over the past two weeks, I’ve changed the implementation of how we service docker models to the user, we noticed that build times for ubuntu images with both the frontend and backend on them were slow, and the images themselves were rather large, 1 to 2 GB. We also noticed that each time we built the image, we were also building the frontend, which was unnecessary. Furthermore, the image was running two services, one to serve the frontend and one to serve the backend. After researching this, many say you should never have two services running on the same image, its bad practice and you should split services out as much as possible. Build times on a 1GB shared CPU Linode server aren’t quick, and the longer the build times, the less usable our system is.

To fix this, we now provide the user with two images, one frontend image which is pre-built and the same for all downloads, one backend image, a docker compose and a readme with the necessary commands to run the images. When the user downloads this, they simply must load both images and run `docker-compose up`. This greatly reduced build times and file sizes are now around 500MB as opposed to over a 1GB.

Obviously, it has its draw backs as the user now has multiple files to deal with, its less contained. and one must run 3 commands instead of 2, but we think the reduction in build times and file sizes is worth it, especially considering the amount of storage on the Linode serve, 25GB.

I have also removed multi arch support as I tested a linux/amd64 docker image on an Apple silicon mac, an intel mac and an intel windows machine and it worked on all of them, so having to build 2 images just isn’t necessary, again reducing pesky build times.