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

    Thanks :D, it solved my problems!

  2. So how does the DNS setting work ?

  3. Nevermind, I thought would allow web hosting from within the docker image. It doesn’t seem to allow that.

  4. Very useful Adrian, thanks!

  5. alpine:~# docker login –username=tufandeveci
    Error response from daemon: Get authorization server did not include a token in the response

    • Might be the version of docker you are using. I would try updating docker and trying again.

      If that doesn’t work, you can contact canister, they have helped me in the past.

    • well you have to create a repo in your account with the same name manually like if your image ends with my-repo then you should have my-repo on your repositories created manually from the website

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.