Skip to content

Commit 34b3a2f

Browse files
committed
cahnged how the username is called
1 parent 3003112 commit 34b3a2f

File tree

2 files changed

+9
-11
lines changed

2 files changed

+9
-11
lines changed

.github/workflows/main.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,4 @@ jobs:
2525

2626
push-docker-image:
2727
uses: ./.github/workflows/push-docker-image.yml
28-
needs: unit-sec-scan
29-
secrets:
30-
password: ${{ secrets.GHCR_TOKEN }}
31-
username: ${{ github.actor }}
28+
needs: build-image

.github/workflows/push-docker-image.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,20 @@ name: Push Docker Image
33

44
on:
55
workflow_call:
6-
secrets:
7-
# GitHub Container Registry token
8-
GHCR_TOKEN:
9-
required: true
6+
107
env:
118
# Use docker.io for Docker Hub if empty
129
REGISTRY: ghcr.io
1310
IMAGE_NAME: ${{ github.repository }}
1411
username: ${{ github.actor }}
1512

1613
jobs:
17-
build:
18-
14+
Push_Image:
15+
permissions:
16+
security-events: write
17+
contents: read
18+
id-token: write
19+
actions: read
1920
runs-on: ubuntu-latest
2021
steps:
2122
- name: Checkout repository
@@ -29,7 +30,7 @@ jobs:
2930
with:
3031
registry: ${{ env.REGISTRY }}
3132
username: ${{ github.actor }}
32-
password: ${{ secrets.GHCR_TOKEN }}
33+
password: ${{ secrets.GIT_TOKEN }}
3334

3435

3536

0 commit comments

Comments
 (0)