Dot Net For All

docker push requested access to the resource is denied : solution

Hello, you might encounter the error –> docker push requested access to the resource is denied while pushing a docker images to docker hub.

Below is the solution for same.

How to push Docker image to Docker repository

Once the image is ready, you can push the image to the docker hub repository. This will help other users to use your image without installing any other prerequisites to their local environment.

Here are the steps worked for me :

1) Login to the docker.

docker login -u {username}

2) Tag your image build

my image name here is : dotnetforall/loans and by default it has tag : latest and my username is : vikramvee as registered with docker cloud, and I created a public repository named : loans

so my personal repository becomes now : vikramvee/loans and I want to push my image with tag : latest .

I tagged as below :

docker tag dotnetforall/loans:latest vikramvee/loans:latest

Pushed the image to my personal docker repository as below:

docker push vikramvee/loans:latest

And the publicly available in my repository as shown in below screenshot.

Top career enhancing courses you can't miss

My Learning Resource

Excel your system design interview