Uploaded image for project: 'Bitbucket Cloud'
  1. Bitbucket Cloud
  2. BCLOUD-15501

Docker push failed: unauthorized: authentication required

    XMLWordPrintable

Details

    Description

      Our pipeline pushes docker image to a private owned registry. It has been working until few days ago. Docker pushes started failing due to unauthorized: authentication required errors.

      Please see log as following:

      #!shell
      
      docker login --username=$CCE_REGISTRY_UNAME --password=$CCE_REGISTRY_PWD <registry>
      9s
      
      + docker login --username=$BAIDU_CCE_REGISTRY_UNAME --password=$BAIDU_CCE_REGISTRY_PWD <registry>
      Login Succeeded
      docker build -t <registry>/<namespace>/<image>:$BITBUCKET_TAG .
      18s
      docker push <registry>/<namespace>/<image>:$BITBUCKET_TAG
      30m 16s
      
      + docker push <registry>/<namespace>/<image>:$BITBUCKET_TAG
      The push refers to a repository [<registry>/<namespace>/<image>]
      d7c237ef87fc: Preparing
      69cc5717c281: Preparing
      5b1e27e74327: Preparing
      04a094fe844e: Preparing
      5b1e27e74327: Pushed
      04a094fe844e: Pushed
      69cc5717c281: Retrying in 5 seconds
      69cc5717c281: Retrying in 4 seconds
      69cc5717c281: Retrying in 3 seconds
      69cc5717c281: Retrying in 2 seconds
      69cc5717c281: Retrying in 1 second
      69cc5717c281: Pushed
      unauthorized: authentication required
      
      

      As you can see, login was successful, it managed to push some part of the image, then eventually failed due to unauthorized: authentication required.

      Did anything change recently that could cause this? Can you help debugging on this?

      (Pushing from localhost using the exact same steps works fine)

      Attachments

        Activity

          People

            matt@atlassian.com Matt Ryall
            d2bea29950f5 yaxing-c
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: