Skip to content

Build bootstrap ISO #23

Build bootstrap ISO

Build bootstrap ISO #23

name: "Build bootstrap ISO"
on:
workflow_dispatch: # runs whenever I want it to
# schedule:
# - cron: '0 0 1 * *' # runs monthly at 00:00
# push:
# branches:
# - main
# paths-ignore:
# - '.github/**'
# - '.vscode/**'
# - 'docs/**'
jobs:
build-iso:
runs-on: ubuntu-latest
permissions:
contents: write # FUCKING GITHUB PERMISSIONS DOCUMENTATION IS UNCLEAR
deployments: write
steps:
- uses: actions/checkout@v4
- name: Check Nix flake inputs against policy
uses: DeterminateSystems/flake-checker-action@v5
- name: Install Nix
uses: DeterminateSystems/nix-installer-action@v9
- name: Prepare nix cache
uses: DeterminateSystems/magic-nix-cache-action@v3
- name: Build default package
run: |
nix build --log-format raw
- name: Create Github release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release delete latest --cleanup-tag --yes || true
image=$(find $(readlink -f ./result) -name 'nixos-*iso' -xtype f -print -quit)
gh release create latest --prerelease --generate-notes "$image"