Host your Docker images for free with

I’m slowly incrementing the number of projects I host in my personal servers and as the number increases I find the need to standardize the way I deploy each service. Currently each service has a different way of running and I have to try to remember how to do it each time I have an update. As one of the steps to a more streamlined deploy process I decided for each service to have a production ready image hosted in a Docker registry. The deploy will then just be a matter of downloading and running the image in the production machine (not perfect, but a step forward).

My first idea was to host a Docker registry myself, but luckily I found a service that offers 20 private repositories for free. To start using, you just need to register for the basic plan and create a new repo.

To push images you can use the command line. Start by logging in:

docker login --username=username

The next step is to tag an image that you want to publish:

docker tag ae5da82730b1

Notice the format of the tag: <registry-url-including-port>/<username>/<repo-name>:<tag>. I used latest as my tag name but you can use any tag name you want.

Finally we just need to push the tag:

docker push

Note that this command doesn’t include the tag being pushed. It will push all tags in the given repo.

For the deploy I had to do something similar. First, log in to in the production server:

docker login --username=username

Pull the image:

docker pull

And finally start it:

docker run -d --restart=on-failure --name my-service-container

Leave a Comment

NOTE - You can use these HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

Time limit is exhausted. Please reload CAPTCHA.