Skip to content

Commit 307b657

Browse files
committed
ci: Add contents: read permission to reusable worflow callers
1 parent 22ff654 commit 307b657

25 files changed

Lines changed: 50 additions & 0 deletions

.github/workflows/build_airflow.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ jobs:
3131
secrets:
3232
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3333
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
34+
permissions:
35+
contents: read
3436
with:
3537
product-name: airflow
3638
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_druid.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ jobs:
3333
secrets:
3434
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3535
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
36+
permissions:
37+
contents: read
3638
with:
3739
product-name: druid
3840
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_hadoop.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ jobs:
3333
secrets:
3434
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3535
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
36+
permissions:
37+
contents: read
3638
with:
3739
product-name: hadoop
3840
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_hbase.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ jobs:
3434
secrets:
3535
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3636
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
37+
permissions:
38+
contents: read
3739
with:
3840
product-name: hbase
3941
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_hive.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ jobs:
3434
secrets:
3535
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3636
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
37+
permissions:
38+
contents: read
3739
with:
3840
product-name: hive
3941
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_java-base.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ jobs:
2929
secrets:
3030
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3131
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
32+
permissions:
33+
contents: read
3234
with:
3335
product-name: java-base
3436
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_java-devel.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ jobs:
2929
secrets:
3030
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3131
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
32+
permissions:
33+
contents: read
3234
with:
3335
product-name: java-devel
3436
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_kafka-testing-tools.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ jobs:
3333
secrets:
3434
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3535
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
36+
permissions:
37+
contents: read
3638
with:
3739
product-name: kafka-testing-tools
3840
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_kafka.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ jobs:
3434
secrets:
3535
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3636
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
37+
permissions:
38+
contents: read
3739
with:
3840
product-name: kafka
3941
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

.github/workflows/build_krb5.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ jobs:
2929
secrets:
3030
harbor-robot-secret: ${{ secrets.HARBOR_ROBOT_SDP_GITHUB_ACTION_BUILD_SECRET }}
3131
slack-token: ${{ secrets.SLACK_CONTAINER_IMAGE_TOKEN }}
32+
permissions:
33+
contents: read
3234
with:
3335
product-name: krb5
3436
sdp-version: ${{ github.ref_type == 'tag' && github.ref_name || '0.0.0-dev' }}

0 commit comments

Comments
 (0)