<p>I followed the <a href="https://learn.microsoft.com/en-us/azure/container-registry/container-registry-auth-aks" rel="nofollow noreferrer">guide here</a> (Grant AKS access to ACR), but am still getting "unauthorized: authentication required" when a Pod is attempting to pull an image from ACR.</p>

<p>The bash script executed without any errors. I have tried deleting my <code>Deployment</code> and creating it from scratch <code>kubectl apply -f ...</code>, no luck.</p>

<p>I would like to avoid using the 2nd approach of using a secret.</p>

Jeff
<p>The link you posted in the question is the correct steps for Authenticate with Azure Container Registry from Azure Kubernetes Service. I tried before and it works well.</p>

<p>So I suggest you can check if the service-principal-ID and service-principal-password are correct in the command <code>kubectl create secret docker-registry acr-auth --docker-server &lt;acr-login-server&gt; --docker-username &lt;service-principal-ID&gt; --docker-password &lt;service-principal-password&gt; --docker-email &lt;email-address&gt;</code>. And the secret you set in the yaml file should also be check if the same as the secret you created. </p>
