Skip to content

Update actions version on-push.yml #32

Update actions version on-push.yml

Update actions version on-push.yml #32

Workflow file for this run

name: Build image on push or PR
on:
push:
branches:
- master
paths:
- 'pi-gen/**'
- 'packages/**'
- '.github/workflows/on-push.yml'
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
working-directory: pi-gen
steps:
- uses: actions/checkout@v4
- name: Register binfmt_misc entries
run: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
- name: Run build script
run: sudo PIGEN_DOCKER_OPTS="-e DEPLOY_XZ=1" ./build-docker.sh
- name: List deploy directory
run: ls -al deploy/
- name: Set image name
run: |
IMAGE_NAME="p4pi-$(date +'%Y-%m-%d')-$(git rev-parse --short=8 HEAD)"
echo "IMAGE_NAME=$IMAGE_NAME" >> $GITHUB_ENV
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.IMAGE_NAME }}
path: pi-gen/deploy/*.zip
if-no-files-found: error
retention-days: 90