GitHub Actions not able to access Docker image from private registry in multi-stage build
I've been banging my head against this for hours. I'm performance testing and I'm working with an scenario with my GitHub Actions workflow where it fails to pull a Docker image from a private registry during a multi-stage build. My workflow file looks like this: ```yaml name: CI on: push: branches: - main jobs: build: runs-on: ubuntu-latest steps: - name: Checkout code uses: actions/checkout@v2 - name: Log in to Docker Hub uses: docker/login-action@v1 with: username: ${{ secrets.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} - name: Build Docker image run: | docker build -t myapp . - name: Push Docker image run: | docker push myapp ``` In the Dockerfile, I'm attempting to use a base image from my private registry: ```dockerfile FROM myprivateregistry/mybaseimage:latest ... ``` However, I keep getting the following behavior when the workflow runs: ``` behavior: manifest for myprivateregistry/mybaseimage:latest not found ``` I've double-checked that the credentials stored in GitHub Secrets are correct and that I can manually pull the image using the same credentials on my local machine. Additionally, I've verified the image exists in the private registry and is tagged as `latest`. I've tried adding a `docker login` command in the build step before the `docker build` command, but it still doesn't work. I also considered that the image might not be available during the time the workflow runs. Is there a way to ensure that the Docker login is effective for the entire job or any other best practices I should follow for accessing private images in GitHub Actions? This is part of a larger desktop app I'm building. How would you solve this?