|
56 | 56 | working_directory: backend/api |
57 | 57 | azure_subscription_id: ${{ vars.AZURE_SUBSCRIPTION_ID }} |
58 | 58 |
|
| 59 | + copy-images-to-robotics-prod-registry: |
| 60 | + name: Copy staging images to robotics prod registry |
| 61 | + needs: [get_staging_version, trigger-github-deployment] |
| 62 | + runs-on: ubuntu-latest |
| 63 | + strategy: |
| 64 | + matrix: |
| 65 | + component: [broker, backend, frontend] |
| 66 | + steps: |
| 67 | + - name: Log in to robotics staging registry |
| 68 | + uses: docker/login-action@v3 |
| 69 | + with: |
| 70 | + registry: roboticsstagingacr.azurecr.io |
| 71 | + username: ${{ secrets.ROBOTICS_ROBOTICSSTAGINGACR_USERNAME }} |
| 72 | + password: ${{ secrets.ROBOTICS_ROBOTICSSTAGINGACR_PASSWORD }} |
| 73 | + |
| 74 | + - name: Log in to robotics prod registry |
| 75 | + uses: docker/login-action@v3 |
| 76 | + with: |
| 77 | + registry: roboticsprodacr.azurecr.io |
| 78 | + username: ${{ secrets.ROBOTICS_ROBOTICSPRODACR_USERNAME }} |
| 79 | + password: ${{ secrets.ROBOTICS_ROBOTICSPRODACR_PASSWORD }} |
| 80 | + |
| 81 | + - name: Copy image from staging to prod registry |
| 82 | + run: | |
| 83 | + docker buildx imagetools create \ |
| 84 | + --tag roboticsprodacr.azurecr.io/robotics/flotilla-${{ matrix.component }}:${{ needs.get_staging_version.outputs.versionTag }} \ |
| 85 | + --tag roboticsprodacr.azurecr.io/robotics/flotilla-${{ matrix.component }}:latest \ |
| 86 | + roboticsstagingacr.azurecr.io/robotics/flotilla-${{ matrix.component }}:${{ needs.get_staging_version.outputs.versionTag }} |
| 87 | +
|
59 | 88 | deploy: |
60 | 89 | name: Update deployment in Production |
61 | | - needs: [get_staging_version, trigger-github-deployment] |
| 90 | + needs: [get_staging_version, trigger-github-deployment, copy-images-to-robotics-prod-registry] |
62 | 91 | strategy: |
63 | 92 | max-parallel: 1 |
64 | 93 | matrix: |
|
0 commit comments