Skip to content

Commit 45a3ec2

Browse files
authored
Merge pull request #69 from Azure/fix/ci-permission-failure
Added permission write to Build_Push_Image job.
2 parents d36e3ae + 16eaa9f commit 45a3ec2

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

.github/workflows/ci.yaml

+7-8
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
1-
21
name: CI
32

43
on:
54
push:
65
branches:
76
- main
8-
97

108
jobs:
119
code_quality_checks:
@@ -17,27 +15,29 @@ jobs:
1715
name: Linting
1816
if: "true"
1917
with:
20-
path: ./src
18+
path: ./src
2119
- uses: hadolint/[email protected]
2220
name: Docker Linting
2321
with:
2422
dockerfile: ./src/Dockerfile
2523
- name: MD Linting
26-
uses: actionshub/markdownlint@main
24+
uses: actionshub/markdownlint@main
2725
- name: Stay woke
2826
uses: get-woke/woke-action@v0
2927
with:
3028
# Cause the check to fail on any broke rules
31-
fail-on-error: true
29+
fail-on-error: true
3230

3331
Build_Push_Image:
3432
runs-on: ubuntu-latest
3533
needs: code_quality_checks
34+
permissions:
35+
packages: write
3636
steps:
3737
- name: Checkout
3838
uses: actions/checkout@v2
3939
- name: Login to DockerHub
40-
uses: docker/login-action@v1
40+
uses: docker/login-action@v1
4141
with:
4242
registry: ghcr.io
4343
username: ${{ github.actor }}
@@ -53,7 +53,7 @@ jobs:
5353
with:
5454
push: true
5555
context: ./src
56-
tags: ghcr.io/azure/gitops-connector:${{ env.IMAGE_TAG }}, ghcr.io/azure/gitops-connector:latest
56+
tags: ghcr.io/azure/gitops-connector:${{ env.IMAGE_TAG }}, ghcr.io/azure/gitops-connector:latest
5757
- name: Upload Image Tags
5858
uses: actions/[email protected]
5959
with:
@@ -64,4 +64,3 @@ jobs:
6464
with:
6565
name: manifests
6666
path: ${{ github.workspace }}/manifests
67-

0 commit comments

Comments
 (0)