Skip to content

Commit

Permalink
Fix Push image (#8)
Browse files Browse the repository at this point in the history
* Push image

* Test permissions
  • Loading branch information
mcbenjemaa authored Nov 29, 2023
1 parent 45f5888 commit 313fa6d
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/container-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ on:
- main
- release-*

permissions:
contents: write
packages: write

jobs:
image:
name: build image
Expand All @@ -28,18 +32,18 @@ jobs:
images: ghcr.io/ionos-cloud/cluster-api-provider-proxmox

- name: Login to GitHub Container Registry
if: github.event_name != 'pull_request'
# if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ secrets.BOT_USERNAME }}
password: ${{ secrets.BOT_PAT }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: .
push: ${{ github.event_name != 'pull_request' }}
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

Expand Down

0 comments on commit 313fa6d

Please sign in to comment.