Skip to main content

Pushing Images

Let's get hands-on and push an image to our project.

Using Docker, we'll need to log in to our Harbor, just like we do with Docker Hub.

Since this study is in a local environment without HTTPS enabled, it's necessary to allow Docker to log in to insecure repositories. To do this, we'll adjust the Docker configuration.

If necessary, create the daemon.json file and set the Harbor local address and port as insecure.

cat /etc/docker/daemon.json
{
"insecure-registries" : ["localhost:39541", "0.0.0.0"]
}

❯ systemctl restart docker.service

❯ systemctl status docker
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset>
Active: active (running) since Mon 2024-11-04 14:25:29 -03; 7s ago
TriggeredBy: ● docker.socket
Docs: https://docs.docker.com
...