Skip to content

Commit

Permalink
Merge pull request #400 from alexsnaps/gh_local_repo
Browse files Browse the repository at this point in the history
Only run some actions on main repo
  • Loading branch information
alexsnaps authored Dec 10, 2024
2 parents bf6a26f + 2f15df8 commit 4bccb34
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/build-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,19 +100,23 @@ jobs:
# set ref name tag for non-main branches
type=raw,value=${{ github.ref_name }},enable=${{ github.ref_name != env.MAIN_BRANCH_NAME }}
- name: Login to container registry
if: github.repository == 'Kuadrant/limitador'
uses: docker/login-action@v2
with:
username: ${{ secrets.IMG_REGISTRY_USERNAME }}
password: ${{ secrets.IMG_REGISTRY_TOKEN }}
registry: ${{ env.IMG_REGISTRY_HOST }}
- name: Create manifest list and push
if: github.repository == 'Kuadrant/limitador'
working-directory: /tmp/digests
run: |
docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
$(printf '${{ env.IMG_REGISTRY_HOST }}/${{ env.IMG_REGISTRY_ORG }}/limitador@sha256:%s ' $(find . -type f -exec basename {} \;))
- name: Inspect image
if: github.repository == 'Kuadrant/limitador'
run: |
docker buildx imagetools inspect ${{ env.IMG_REGISTRY_HOST }}/${{ env.IMG_REGISTRY_ORG }}/limitador:${{ steps.meta.outputs.version }}
- name: Smoke Test
if: github.repository == 'Kuadrant/limitador'
run: |
docker run --rm -t ${{ env.IMG_REGISTRY_HOST }}/${{ env.IMG_REGISTRY_ORG }}/limitador:${{ steps.meta.outputs.version }} limitador-server --help
2 changes: 2 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
jobs:
check:
name: Check
if: github.repository == 'Kuadrant/limitador'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -23,6 +24,7 @@ jobs:

test:
name: Test Suite
if: github.repository == 'Kuadrant/limitador'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/license-scan.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
jobs:
fossa-scan:
name: Find license compliance and security issues
if: github.repository == 'Kuadrant/limitador' && secrets.FOSSA_API_TOKEN != null
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
jobs:
publish:
name: Publish Limitador crate to crates.io
if: github.repository == 'Kuadrant/limitador'
runs-on: ubuntu-latest
steps:
- uses: abelfodil/protoc-action@v1
Expand Down

0 comments on commit 4bccb34

Please sign in to comment.