10000 GithubActions: skip tinybird, docker push and docker login in forks (… · localstack/localstack@4de49e9 · GitHub
[go: up one dir, main page]

Skip to content

Commit 4de49e9

Browse files
authored
GithubActions: skip tinybird, docker push and docker login in forks (#12639)
1 parent 167d820 commit 4de49e9

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

.github/workflows/aws-main.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ jobs:
172172
# push image on master, target branch not set, and the dependent steps were either successful or skipped
173173
# TO-DO: enable job after workflow in CircleCI is disabled
174174
if: false
175-
# if: github.ref == 'refs/heads/master' && !failure() && !cancelled()
175+
# if: github.ref == 'refs/heads/master' && !failure() && !cancelled() && github.repository == 'localstack/localstack'
176176
needs:
177177
# all tests need to be successful for the image to be pushed
178178
- test
@@ -252,7 +252,7 @@ jobs:
252252
253253
push-to-tinybird:
254254
name: Push Workflow Status to Tinybird
255-
if: always() && github.ref == 'refs/heads/master'
255+
if: always() && github.ref == 'refs/heads/master' && github.repository == 'localstack/localstack'
256256
runs-on: ubuntu-latest
257257
needs:
258258
- test

.github/workflows/aws-tests-mamr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ jobs:
6666

6767
push-to-tinybird:
6868
name: Push Workflow Status to Tinybird
69-
if: always() && github.ref == 'refs/heads/master'
69+
if: always() && github.ref == 'refs/heads/master' && github.repository == 'localstack/localstack'
7070
runs-on: ubuntu-latest
7171
needs:
7272
- test-ma-mr

.github/workflows/aws-tests.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,6 +284,7 @@ jobs:
284284

285285
- name: Login to Docker Hub
286286
# login to DockerHub to avoid rate limiting issues on custom runners
287+
if: github.repository_owner == 'localstack'
287288
uses: docker/login-action@v3
288289
with:
289290
username: ${{ secrets.DOCKERHUB_PULL_USERNAME }}
@@ -431,6 +432,7 @@ jobs:
431432

432433
- name: Login to Docker Hub
433434
# login to DockerHub to avoid rate limiting issues on custom runners
435+
if: github.repository_owner == 'localstack'
434436
uses: docker/login-action@v3
435437
with:
436438
username: ${{ secrets.DOCKERHUB_PULL_USERNAME }}
@@ -679,6 +681,7 @@ jobs:
679681
steps:
680682
- name: Login to Docker Hub
681683
# login to DockerHub to avoid rate limiting issues on custom runners
684+
if: github.repository_owner == 'localstack'
682685
uses: docker/login-action@v3
683686
with:
684687
username: ${{ secrets.DOCKERHUB_PULL_USERNAME }}

0 commit comments

Comments
 (0)
0