Build LXC image #30
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: Build LXC image | ||
on: | ||
workflow_dispatch: | ||
concurrency: | ||
group: | ||
env: | ||
os: mageia | ||
jobs: | ||
clone-repo: | ||
name: Clone repo | ||
uses: ./.github/workflows/checkout-self-hosted.yaml | ||
build-rootfs: | ||
name: Build rootfs | ||
needs: clone-repo | ||
uses: ./.github/workflows/build-rootfs.yaml | ||
build-for-target: | ||
name: Build for target | ||
runs-on: self-hosted | ||
needs: build-rootfs | ||
steps: | ||
- name: Cache build | ||
id: build | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
./out/rootfs.tar.xz | ||
./out/meta.tar.xz | ||
key: image-${{ env.os }}-lxc-${{ hashFiles('*.sqfs', '*.yaml') }} | ||
- name: Make build-lxc | ||
if: steps.build.outputs.cache-hit != 'true' | ||
run: make build-lxc | ||
- name: Upload image | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: image-${{ env.os }}-lxc | ||
path: | | ||
./out/rootfs.tar.xz | ||
./out/meta.tar.xz |