Skip to content

Commit

Permalink
fix(ghrunner): fix release pipeline for self-hosted runner (#994)
Browse files Browse the repository at this point in the history
* Altinn has uppercase, thats not allowed in ghcr.io
* Remove ghrunner- prefix from image tag

---------

Co-authored-by: tjololo <1145298+tjololo@users.noreply.github.com>
Co-authored-by: Renato Monteiro <45536168+monteiro-renato@users.noreply.github.com>
  • Loading branch information
3 people authored Oct 11, 2024
1 parent 6bdf506 commit 13ff446
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions .github/workflows/gh-runner-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get version from tags
id: version
- name: Get variables from tags
id: vars
run: |
tag=${GITHUB_REF/refs\/tags\//}
tag=${GITHUB_REF/refs\/tags\/ghrunner-/}
echo "version=${tag%-demo}" >> $GITHUB_OUTPUT
echo "reponame=${GITHUB_REPOSITORY,,}" >>${GITHUB_OUTPUT}
- name: Get Git commit timestamps
run: echo "TIMESTAMP=$(git log -1 --pretty=%ct)" >> $GITHUB_ENV
- name: Set up QEMU
Expand All @@ -38,6 +39,6 @@ jobs:
context: ./infrastructure/images/gh-runner
push: true
platforms: linux/amd64,linux/arm64
tags: ghcr.io/${{ github.repository }}/gh-runner:v${{ steps.version.outputs.version }}
tags: ghcr.io/${{ steps.vars.outputs.reponame }}/gh-runner:v${{ steps.vars.outputs.version }}
env:
SOURCE_DATE_EPOCH: ${{ env.TIMESTAMP }}
SOURCE_DATE_EPOCH: ${{ env.TIMESTAMP }}

0 comments on commit 13ff446

Please sign in to comment.