My azure function app fails to pull a docker image from my private repository (despite presence of DOCKER_REGISTRY_SERVER_USERNAME and DOCKER_REGISTRY_SERVER_PASSWORD)

Leo Keogh 0 Reputation points
2023-02-15T13:21:20.0633333+00:00

Hello,

My azure function app fails to pull a docker image from my private repository.

I have correctly added DOCKER_REGISTRY_SERVER_USERNAME and DOCKER_REGISTRY_SERVER_PASSWORD to Configuration Settings. I have also put the user/password in Deployment Center settings.

These credentials allow me to pull the image using command shell.

The logs in the Function App Deployment Center:

2023-02-15T13:08:28.512Z ERROR - Pulling docker image semarchy/xdm-purview-connector-internal:v1.0.0 failed: 2023-02-15T13:08:28.574Z ERROR - DockerApiException: Docker API responded with status code=NotFound, response={"message":"pull access denied for semarchy/xdm-purview-connector-internal, repository does not exist or may require 'docker login': denied: requested access to the resource is denied"}

Does the Function App need special docker hub credentials for image pull?

Any help with this would be much appreciated.

Thanks,

Leo Keogh.

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
5,911 questions
{count} votes

1 answer

Sort by: Most helpful
  1. MikeUrnun 9,777 Reputation points Moderator
    2023-02-23T06:08:37.8533333+00:00

    Hello @Leo Keogh - The doc states the following on publishing to a private registry:
    User's image

    And the Pull should occur automatically after the detection of a newer image on the registry. Is the issue you're facing the same authentication not working when pulling? If so, please try running the following after the creation of the private image:

    az webapp config container set -n <functioname> -g <resourcegroup> -c <yourCONTAINER_PATH> -r <registry_URL> -u <username> -p <password>
    

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.