diff --git a/.github/workflows/debian.yml b/.github/workflows/debian.yml index 623554c..bd352e4 100644 --- a/.github/workflows/debian.yml +++ b/.github/workflows/debian.yml @@ -1,7 +1,14 @@ name: Debian on: + pull_request: + paths: + - .github/workflows/debian.yml + - docker/debian/Dockerfile* + - test push: + branches: + - main paths: - .github/workflows/debian.yml - docker/debian/Dockerfile* @@ -17,7 +24,7 @@ defaults: shell: bash env: - PUSH: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + PUSH: ${{ github.event_name == 'push' }} CONTAINER_REGISTRY: ghcr.io BUILDKIT_PROGRESS: plain CONAN_VERSION: 2.19.1 @@ -87,6 +94,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} @@ -161,7 +169,7 @@ jobs: retention-days: 1 merge: - if: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + if: ${{ github.event_name == 'push' }} strategy: matrix: os: @@ -221,6 +229,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} diff --git a/.github/workflows/gcc.yml b/.github/workflows/gcc.yml index 07e7a61..3c494c5 100644 --- a/.github/workflows/gcc.yml +++ b/.github/workflows/gcc.yml @@ -1,7 +1,13 @@ name: GCC on: + pull_request: + paths: + - .github/workflows/gcc.yml + - docker/gcc/Dockerfile* push: + branches: + - main paths: - .github/workflows/gcc.yml - docker/gcc/Dockerfile* @@ -16,7 +22,7 @@ defaults: shell: bash env: - PUSH: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + PUSH: ${{ github.event_name == 'push' }} CONTAINER_REGISTRY: ghcr.io BUILDKIT_PROGRESS: plain @@ -49,6 +55,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} @@ -109,7 +116,7 @@ jobs: retention-days: 1 merge: - if: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + if: ${{ github.event_name == 'push' }} strategy: matrix: os: @@ -138,6 +145,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} diff --git a/.github/workflows/rhel.yml b/.github/workflows/rhel.yml index ba14484..c5a2ba9 100644 --- a/.github/workflows/rhel.yml +++ b/.github/workflows/rhel.yml @@ -1,7 +1,14 @@ name: RHEL on: + pull_request: + paths: + - .github/workflows/rhel.yml + - docker/rhel/Dockerfile + - test push: + branches: + - main paths: - .github/workflows/rhel.yml - docker/rhel/Dockerfile @@ -17,7 +24,7 @@ defaults: shell: bash env: - PUSH: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + PUSH: ${{ github.event_name == 'push' }} CONTAINER_REGISTRY: ghcr.io REDHAT_REGISTRY: registry.access.redhat.com BUILDKIT_PROGRESS: plain @@ -66,12 +73,14 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} username: ${{ github.repository_owner }} password: ${{ secrets.GITHUB_TOKEN }} - name: Login to Red Hat Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.REDHAT_REGISTRY }} @@ -141,7 +150,7 @@ jobs: retention-days: 1 merge: - if: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + if: ${{ github.event_name == 'push' }} strategy: matrix: os: @@ -180,6 +189,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} diff --git a/.github/workflows/tools-rippled.yml b/.github/workflows/tools-rippled.yml index fbdfd7e..9ae6d3d 100644 --- a/.github/workflows/tools-rippled.yml +++ b/.github/workflows/tools-rippled.yml @@ -1,7 +1,13 @@ name: Tools-rippled on: + pull_request: + paths: + - .github/workflows/tools-rippled.yml + - docker/tools-rippled/Dockerfile push: + branches: + - main paths: - .github/workflows/tools-rippled.yml - docker/tools-rippled/Dockerfile @@ -16,7 +22,7 @@ defaults: shell: bash env: - PUSH: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + PUSH: ${{ github.event_name == 'push' }} CONTAINER_REGISTRY: ghcr.io BUILDKIT_PROGRESS: plain CMAKE_VERSION: 3.31.6 @@ -47,6 +53,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} @@ -115,7 +122,7 @@ jobs: retention-days: 1 merge: - if: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + if: ${{ github.event_name == 'push' }} strategy: matrix: tool: @@ -138,6 +145,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index 47a63cf..4b62968 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -1,7 +1,14 @@ name: Ubuntu on: + pull_request: + paths: + - .github/workflows/ubuntu.yml + - docker/ubuntu/Dockerfile + - test push: + branches: + - main paths: - .github/workflows/ubuntu.yml - docker/ubuntu/Dockerfile @@ -17,7 +24,7 @@ defaults: shell: bash env: - PUSH: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + PUSH: ${{ github.event_name == 'push' }} CONTAINER_REGISTRY: ghcr.io BUILDKIT_PROGRESS: plain CONAN_VERSION: 2.19.1 @@ -70,6 +77,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }} @@ -140,7 +148,7 @@ jobs: retention-days: 1 merge: - if: ${{ github.ref_type == 'branch' && github.ref_name == github.event.repository.default_branch }} + if: ${{ github.event_name == 'push' }} strategy: matrix: os: @@ -182,6 +190,7 @@ jobs: - name: Set up Docker Buildx uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1 - name: Login to GitHub Registry + if: ${{ github.event_name == 'push' }} uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0 with: registry: ${{ env.CONTAINER_REGISTRY }}