kamal icon indicating copy to clipboard operation
kamal copied to clipboard

Kamal powered Docker registry and remote builder

Open dalton-cole opened this issue 6 months ago • 2 comments

I created Knot, a deploy script that uses Kamal 2 to self-host a Docker registry and remote builder. I have been using that self-hosted registry for all of my Kamal 2 projects, which is pretty sweet. Takes about a minute to go from cloning to repo to running your registry, it comes with all the goodies you expect from a Kamal deploy like SSL.

I would love to find a way to improve it together. It could be very useful for organizations that use Macs to deploy to AMD servers or don't want to pay $12/head for Docker Pro.

https://github.com/deployTo-Dev/knot https://knot.deployto.dev/

dalton-cole avatar Jun 16 '25 13:06 dalton-cole

Hey @dalton-cole!

There's a PR to use a local registry here - https://github.com/basecamp/kamal/pull/1355. It starts the registry on the host you are deploying from and then uses an SSH tunnel to expose the registry on localhost on hosts that we are deploying to.

I'll hopefully get that merged into Kamal at some point soon - there's no blockers for it, I just will need time to deal with any issues that crop up from it and I won't for the next month or two.

The local registry is probably the route we'll go with in Kamal itself as it doesn't require any DNS changes. It maybe doesn't scale that well if you have many hosts though so the self hosted registry approach might work better there.

djmb avatar Jun 17 '25 10:06 djmb

I think a local registry is great. I've had a few issues with building locally on my Mac with Docker Desktop and deploying to AMD chips, so I was initially just focused on a simple remote builder, but figured I'd toss a registry on that server for fun. I think sharing a hosted registry for a team also has some benefits.

dalton-cole avatar Jun 18 '25 15:06 dalton-cole