Docker Images

Docker Images

From the very beginning my approach has been that building your images on remote is an overkill. I made Sidekick for people who are keen to ship and iterate quickly, not spend time building elaborate CICD systems or unnecessary complexity. While other well respected projects will require you to push to your code to your VPS, by connecting your repo or any other way, then build a docker image on your VPS then boot that up, Sidekick takes a different simpler approach.

The docker images are built on your local for your VPS target OS. After this Sidekick will simply save your docker images as a file, copy the file over to your VPS directly in the project folder, load the image onto the docker daemon and then delete the file. This means you don’t need a docker registry to upload your image to either.

This has multiple benefits:

  • Minimalism: only your image belongs to your VPS; not your source code.
  • Security: your code, image, won’t touch anything else but your local and your VPS
  • Simplicity: just your local and your VPS. Nothing else is needed
  • Performance: your VPS won’t be busy building images for a project while handling traffic for another project

I do understand there are cases where building on remote is better - shared cache, more powerful build machine and so on. I would like to push back on that though. If your image is too big/heavy to build locally, probably Sidekick is not for you.

Note:

Originally I made Sidekick to use a registry but one of the very first issues on the repo by lpil suggested we do otherwise; which I did. Yay OSS. 🎊