skip to Main Content

We have an azure yaml pipeline configured to create a container instance from a docker image, this was running fine up to 1st July (yesterday) however from 2nd July (today) the following error is thrown in the pipeline:

ERROR: (RegistryErrorResponse) An error response is received from the docker registry ‘docker.io’. Please retry later.
Code: RegistryErrorResponse
Message: An error response is received from the docker registry ‘docker.io’. Please retry later.

This is the AzureCLI@2 task used to create the container:

- task: AzureCLI@2
  name: CreateContainer
  displayName: Create container
  inputs:
    azureSubscription: ${{ parameters.subscription }}
    scriptType: bash
    scriptLocation: inlineScript
    inlineScript: |
      az container create 
        --resource-group '${{ parameters.resourceGroup }}' 
        --name '${{ parameters.name }}' 
        --image 'docker.io/mockoon/cli:latest' 
        --ports ${{ parameters.port }} 
        --location '${{ parameters.location }}' 
        --dns-name-label '${{ parameters.name }}' 
        --command-line "mockoon-cli start --data '$(publicUrl)' --port ${{ parameters.port }}"`

I’ve tried using a different tag e.g. 8.2.0, 8.1.1, same result
I’ve checked the status here https://www.dockerstatus.com/ and it’s ‘All systems operational’

2

Answers


  1. I can get the same error message when trying to create ACI using the Docker image from Docker Hub. However, it work fine when using the image from ACR.

    As a workaround, you can try to pull, re-build and push the image ‘mockoon/cli:latest’ to ACR using the DevcontainersCi@0 task provided by the "Dev Container Build and Run Task" extension, and then create the ACI using the image from ACR.

    1. Install the Dev Container Build and Run Task extension to your Azure DevOps organization.

    2. In the git repository where you pipeline runs, add a json file ".devcontainer/devcontainer.json" with below content in the root directory.

      {
        "image": "docker.io/mockoon/cli:latest"
      }
      

      enter image description here

    3. Then configure the pipeline like as below.

    steps:
    - task: Docker@2
      displayName: 'Docker Login'
      inputs:
        containerRegistry: 'Name of the Docker Registry service connection' 
        command: login
    
    - task: DevcontainersCi@0
      displayName: 'Build and Run Dev Container'
      inputs:
        imageName: yourregistry.azurecr.io/mockoon_cli
        imageTag: 'latest'
        push: filter
        sourceBranchFilterForPush: refs/heads/main
        noCache: false
    
    - task: AzureCLI@2
      displayName: 'Create ACI'
      inputs:
        azureSubscription: 'Name of the ARM service connection'
        scriptType: 'bash'
        scriptLocation: 'inlineScript'
        inlineScript: |
          az container create 
          -g '${{ parameters.resourceGroup }}' 
          -n '${{ parameters.name }}' 
          -l '${{ parameters.location }}' 
          --ports ${{ parameters.port }} 
          --dns-name-label '${{ parameters.name }}' 
          --registry-username $(username) 
          --registry-password $(password) 
          --image 'yourregistry.azurecr.io/mockoon_cli:latest' 
          --command-line "mockoon-cli start --data '$(publicUrl)' --port ${{ parameters.port }}"`
    

    Login or Signup to reply.
  2. There was a change in the Docker Hub rate limiting policy, the policy was changed to manage the load on its infrastructure and prevent abuse. It was changed on June 30th, changing the rates as follows:

    Anonymous users can extract up to 100 images per 6-hour period.

    Authenticated users (with a Docker account) can pull up to 200 images per 6-hour period.

    Users with a paid Docker license can pull up to 5,000 images per day.

    https://medium.com/@alaa.barqawi/docker-rate-limit-with-azure-container-instance-and-aks-4449cede66dd

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search