From dffac7bbef5adeac6bb3acf2bf275a6184b9b986 Mon Sep 17 00:00:00 2001 From: Scott Exton Date: Wed, 22 Mar 2023 11:34:11 +1000 Subject: [PATCH] Migrate from Docker Hub to ICR. --- .github/workflows/build.yaml | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4e82922..ac402d0 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -81,20 +81,12 @@ jobs: mv operator-sdk_${OS}_${ARCH} ${HOME}/.local/bin/operator-sdk # Perform a docker login to IBM Cloud Container Registry (icr.io) - - name: Login to ICR - env: - API_KEY: ${{ secrets.ICR_API_KEY }} - run: | - echo "Installing the IBM Cloud command line...." - curl -fsSL https://clis.cloud.ibm.com/install/linux | sh - ibmcloud -v - ibmcloud plugin install container-registry - echo "Authenticating to IBM Cloud..." - ibmcloud config --check-version=false - ibmcloud login --apikey ${API_KEY} \ - -a https://cloud.ibm.com -r us-south - ibmcloud cr login --client docker - ibmcloud cr region-set global + - name: Login to IBM Cloud Container Registry + uses: docker/login-action@v2 + with: + registry: icr.io + username: iamapikey + password: ${{ secrets.ICR_API_KEY }} # Perform the build. - name: Perform the build.