Skip to content

Commit c4fc776

Browse files
committed
CCM-12614: add github package manager authentication
1 parent 25f39be commit c4fc776

2 files changed

Lines changed: 11 additions & 1 deletion

File tree

.github/workflows/cicd-1-pull-request.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,14 @@ on:
1515
permissions:
1616
id-token: write
1717
contents: write
18-
packages: read
1918

2019
jobs:
2120
metadata:
2221
name: "Set CI/CD metadata"
2322
runs-on: ubuntu-latest
2423
timeout-minutes: 1
24+
permissions:
25+
contents: read
2526
outputs:
2627
build_datetime_london: ${{ steps.variables.outputs.build_datetime_london }}
2728
build_datetime: ${{ steps.variables.outputs.build_datetime }}
@@ -153,6 +154,9 @@ jobs:
153154
name: Trigger dynamic environment creation
154155
needs: [metadata, build-stage]
155156
runs-on: ubuntu-latest
157+
permissions:
158+
contents: read
159+
id-token: write
156160
if: needs.metadata.outputs.does_pull_request_exist == 'true' || (github.event_name == 'pull_request' && (github.event.action == 'opened' || github.event.action == 'reopened'))
157161
steps:
158162
- uses: actions/checkout@v5.0.0

.github/workflows/stage-1-commit.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,9 @@ jobs:
156156
timeout-minutes: 10
157157
needs: detect-terraform-changes
158158
if: needs.detect-terraform-changes.outputs.terraform_changed == 'true'
159+
permissions:
160+
contents: read
161+
packages: read
159162
env:
160163
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
161164
steps:
@@ -172,6 +175,9 @@ jobs:
172175
name: "Trivy Package Scan"
173176
runs-on: ubuntu-latest
174177
timeout-minutes: 10
178+
permissions:
179+
contents: read
180+
packages: read
175181
env:
176182
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
177183
steps:

0 commit comments

Comments
 (0)