<p>Having trouble with pushing a image to a private repository on DockerHub.
I'm working on a pipeline that package the image successfully but stumble upon an 'access denied' when the docker push command is performed.</p>
<p>It's a Rancher instance that spins up a Jenkins pod and parses a rancher-pipeline.yml file.</p>
<p>The log:</p>
<pre><code>Registry credentials or Docker config not provided. Guest mode enabled.
</code></pre>
<pre><code># repo info adjusted for posting

Successfully built 7dae5217eb36
Successfully tagged 00000000:latest
+ /usr/local/bin/docker tag 00000000 ACCOUNT/REPO:TAG
+ /usr/local/bin/docker push ACCOUNT/REPO:TAG
The push refers to repository [docker.io/ACCOUNT/REPO:TAG]

----

time=&quot;2020-10-08T07:57:29.336029874Z&quot; level=error msg=&quot;Upload failed: denied: requested access to the resource is denied&quot;
time=&quot;2020-10-08T07:57:29.336163885Z&quot; level=info msg=&quot;Attempting next endpoint for push after error: denied: requested access to the resource is denied&quot;
denied: requested access to the resource is denied
time=&quot;2020-10-08T07:57:29Z&quot; level=fatal msg=&quot;exit status 1&quot;```

Pipeline

</code></pre>
<p>Pipeline:</p>
<ul>
<li>name: Publish
steps:
<ul>
<li>publishImageConfig:
dockerfilePath: ./Dockerfile
buildContext: .
tag: REPO:TAG
pushRemote: true
registry: ACCOUNT</li>
</ul>
</li>
</ul>
<pre><code>
I fiddled a lot around with the registry values but with no luck. When building an pushing the image locally i can succesfully push it to my registry. 
</code></pre>

Heffie
<p>Found the solution.
For future reference.</p>
<p>Registry should be:
registry: index.docker.io</p>
<p>Couldn't find this in the docs but after rebuilding this pipeline with the Rancher UI it shows this registry value. To make this work one will also need to have created a Registry Credentials. This can be done in secrets -&gt; Registry Credentials -&gt; add new</p>
