feat(webhook): enforce mandatory webhook secret configuration #2865
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and push image | |
| on: | |
| # restore the following push event once the automatic multi-arch image build is implemented | |
| # push: | |
| # branches: | |
| # - master | |
| pull_request: | |
| branches: | |
| - master | |
| jobs: | |
| build_image: | |
| if: github.repository == 'argoproj-labs/argocd-image-updater' | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 45 | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v6 | |
| with: | |
| path: argocd-image-updater | |
| - name: Setup qemu | |
| uses: docker/setup-qemu-action@v4 | |
| - name: Setup Docker buildx | |
| uses: docker/setup-buildx-action@v4 | |
| - name: Build and possibly push image | |
| run: | | |
| set -ex | |
| MULTIARCH=no | |
| PUSH=no | |
| if [[ "${{ github.event_name }}" == "push" ]]; then | |
| MULTIARCH=yes | |
| PUSH=yes | |
| elif [[ "${{ contains(github.event.pull_request.labels.*.name, 'test-arm-image') }}" == "true" ]]; then | |
| MULTIARCH=yes | |
| fi | |
| if [[ "${PUSH}" == "yes" ]]; then | |
| docker login --username "${DOCKER_USERNAME}" --password "${DOCKER_PASSWORD}" quay.io | |
| fi | |
| if [[ "${MULTIARCH}" = "yes" ]]; then | |
| IMAGE_PUSH=${PUSH} make docker-buildx | |
| else | |
| make docker-build | |
| fi | |
| working-directory: argocd-image-updater | |
| env: | |
| DOCKER_USERNAME: ${{ secrets.QUAY_USERNAME }} | |
| DOCKER_PASSWORD: ${{ secrets.QUAY_TOKEN }} |