Skip to content

Commit

Permalink
Add permission on the job to write packages
Browse files Browse the repository at this point in the history
  • Loading branch information
Odilhao committed Oct 22, 2024
1 parent beba9c0 commit 8ea8517
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,17 @@ on:
push:
branches: [main]



env:
REGISTRY_USER: ${{ github.actor }}
REGISTRY_PASSWORD: ${{ github.token }}
IMAGE_REGISTRY: ghcr.io/odilhao

jobs:
build-swaywm:
permissions:
packages: write
runs-on: ubuntu-24.04
steps:
- name: Log in to ghcr.io
Expand All @@ -21,6 +25,6 @@ jobs:
registry: ${{ env.IMAGE_REGISTRY }}
- uses: actions/checkout@v4
- name: Build container
run: podman build -t ${{ env.IMAGE_REGISTRY }}/bootc-sway:$(echo ${GITHUB_REF} | tr '/' '_') .
run: podman build -t ${{ env.IMAGE_REGISTRY }}/bootc-sway:${{ github.sha }} .
- name: Push Image
run: podman push ${{ env.IMAGE_REGISTRY }}/bootc-sway:$(echo ${GITHUB_REF} | tr '/' '_')
run: podman push ${{ env.IMAGE_REGISTRY }}/bootc-sway:${{ github.sha }}

0 comments on commit 8ea8517

Please sign in to comment.