Run on uid 1673 instead of 1000 #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: main | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ludeeus/[email protected] | |
ci-mark: | |
needs: | |
- lint | |
runs-on: ubuntu-latest | |
steps: | |
- run: echo mark | |
build: | |
needs: ci-mark | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
timeout-minutes: 60 | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
ref: ${{ github.event.pull_request.head.sha }} | |
- uses: docker/[email protected] | |
- uses: docker/setup-buildx-action@v3 | |
- uses: docker/login-action@v3 | |
with: | |
registry: ghcr.io | |
username: ${{ github.repository_owner }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- id: ev | |
run: | | |
if [ -z "${{ github.event.pull_request.head.sha }}" ]; then | |
echo "sha=${GITHUB_SHA}" > "${GITHUB_OUTPUT}" | |
else | |
echo "sha=${{ github.event.pull_request.head.sha }}" > "${GITHUB_OUTPUT}" | |
fi | |
- uses: docker/build-push-action@v5 | |
with: | |
context: . | |
push: "${{ github.ref == 'refs/heads/main' }}" | |
tags: | | |
ghcr.io/authentik-community/krb5:${{ steps.ev.outputs.sha }} | |
platforms: linux/amd64,linux/arm64 | |
build-args: | | |
GIT_BUILD_HASH=${{ steps.ev.outputs.sha }} | |
cache-from: type=gha | |
cache-to: type=gha,mode=max |