mirror of
https://github.com/daylinmorgan/oizys.git
synced 2024-12-27 14:10:45 -06:00
Compare commits
No commits in common. "f1813b4a47e87417d3d32d9078ed0d9c79eec3dd" and "fe4730b82c9633850672d24d32a4d94a05c3fabe" have entirely different histories.
f1813b4a47
...
fe4730b82c
4 changed files with 60 additions and 58 deletions
48
.github/workflows/build.yml
vendored
48
.github/workflows/build.yml
vendored
|
@ -1,39 +1,27 @@
|
|||
name: Build NixOS (on demand)
|
||||
name: Build NixOS
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
host:
|
||||
description: 'host name to build'
|
||||
required: true
|
||||
default: 'othalan'
|
||||
type: string
|
||||
lockFile:
|
||||
description: 'flake.lock file'
|
||||
type: string
|
||||
|
||||
workflow_call:
|
||||
inputs:
|
||||
host:
|
||||
description: 'host name to build'
|
||||
required: true
|
||||
default: 'othalan'
|
||||
type: string
|
||||
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ inputs.host }}
|
||||
cancel-in-progress: true
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
max-parallel: 1
|
||||
matrix:
|
||||
host: ["othalan", "mannaz", "algiz"]
|
||||
steps:
|
||||
# free up some space
|
||||
- run: sudo rm -rf /opt&
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- uses: DeterminateSystems/nix-installer-action@main
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install Nix
|
||||
uses: DeterminateSystems/nix-installer-action@main
|
||||
- uses: DeterminateSystems/magic-nix-cache-action@v2
|
||||
|
||||
- uses: cachix/cachix-action@v14
|
||||
|
@ -41,12 +29,6 @@ jobs:
|
|||
name: daylin
|
||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||
|
||||
- name: write lock file
|
||||
if: "${{ inputs.lockFile != '' }}"
|
||||
run: |
|
||||
echo '${{ inputs.lockFile }}' > flake.lock
|
||||
git diff
|
||||
|
||||
- name: Build
|
||||
run: |
|
||||
nix run . --accept-flake-config -- cache --host "${{ inputs.host }}" --flake .
|
||||
nix run . --accept-flake-config -- cache --host "${{ matrix.host }}" --flake .
|
||||
|
|
45
.github/workflows/on-demand.yml
vendored
Normal file
45
.github/workflows/on-demand.yml
vendored
Normal file
|
@ -0,0 +1,45 @@
|
|||
name: Build NixOS (on demand)
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
host:
|
||||
description: 'host name to build'
|
||||
required: true
|
||||
default: 'othalan'
|
||||
type: string
|
||||
lockFile:
|
||||
description: 'flake.lock file'
|
||||
required: true
|
||||
type: string
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}-${{ github.ref }}
|
||||
cancel-in-progress: true
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
# free up some space
|
||||
- run: sudo rm -rf /opt&
|
||||
|
||||
- uses: actions/checkout@v4
|
||||
- name: Install Nix
|
||||
uses: DeterminateSystems/nix-installer-action@main
|
||||
- uses: DeterminateSystems/magic-nix-cache-action@v2
|
||||
|
||||
- uses: cachix/cachix-action@v14
|
||||
with:
|
||||
name: daylin
|
||||
authToken: "${{ secrets.CACHIX_AUTH_TOKEN }}"
|
||||
|
||||
- name: write lock file
|
||||
run: |
|
||||
echo '${{ inputs.lockFile }}' > flake.lock
|
||||
git diff
|
||||
|
||||
|
||||
- name: Build
|
||||
run: |
|
||||
nix run . --accept-flake-config -- cache --host "${{ inputs.host }}" --flake .
|
23
.github/workflows/push.yml
vendored
23
.github/workflows/push.yml
vendored
|
@ -1,23 +0,0 @@
|
|||
name: Build NixOS
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
pull_request:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
build:
|
||||
strategy:
|
||||
max-parallel: 1
|
||||
matrix:
|
||||
host:
|
||||
- othalan
|
||||
# - mannaz
|
||||
# - algiz
|
||||
uses: ./.github/workflows/build.yml
|
||||
with:
|
||||
host: "${{ matrix.host }}"
|
||||
secrets: inherit
|
2
todo.md
2
todo.md
|
@ -12,6 +12,4 @@
|
|||
|
||||
- [ ] find out why pixi on GHA is different from local (possibly from the fetch git step?)
|
||||
|
||||
- [ ] rework CI so it's not building all systems on every pull
|
||||
|
||||
<!-- generated with <3 by daylinmorgan/todo -->
|
||||
|
|
Loading…
Reference in a new issue