nixos-config/.github/workflows/cachix.yaml

96 lines
2 KiB
YAML
Raw Normal View History

name: "Cachix"
on:
push:
paths:
2022-01-18 11:56:32 +01:00
- '**.nix'
- '**.age'
- 'pkgs/**'
- 'flake.nix'
- 'flake.lock'
- '.github/workflows/cachix.yaml'
jobs:
2022-04-10 11:57:03 +02:00
format-check:
name: Format check
runs-on: ubuntu-latest
steps:
2023-11-15 12:01:30 +01:00
- uses: actions/checkout@v4
2022-04-10 11:57:03 +02:00
- uses: cachix/install-nix-action@v27
2022-04-10 11:57:03 +02:00
- name: Run alejandra
run: nix develop --command alejandra --check .
2022-04-10 11:57:03 +02:00
flake-check:
name: Flake check
runs-on: ubuntu-latest
steps:
2023-11-15 12:01:30 +01:00
- uses: actions/checkout@v4
2024-02-06 17:54:03 +01:00
- uses: cachix/install-nix-action@v25
2024-02-06 17:54:03 +01:00
- uses: cachix/cachix-action@v14
with:
name: alarsyo
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
extraPullNames: "nix-community"
- name: Build package
run: nix flake check
2022-01-18 11:56:32 +01:00
build-pkgs:
name: Nix packages
runs-on: ubuntu-latest
2022-04-10 11:57:03 +02:00
needs: [ flake-check, format-check ]
2022-01-11 11:56:30 +01:00
strategy:
2022-03-24 17:22:02 +01:00
fail-fast: false
2022-01-11 11:56:30 +01:00
matrix:
name:
- grafanaDashboards/nginx
- grafanaDashboards/node-exporter
- kaleidoscope-udev-rules
- sddm-sugar-candy
- spot
steps:
2023-11-15 12:01:30 +01:00
- uses: actions/checkout@v4
2022-01-11 11:56:30 +01:00
2024-02-06 17:54:03 +01:00
- uses: cachix/install-nix-action@v25
2022-01-11 11:56:30 +01:00
2024-02-06 17:54:03 +01:00
- uses: cachix/cachix-action@v14
with:
name: alarsyo
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
2022-01-11 13:47:36 +01:00
extraPullNames: "nix-community"
2022-01-11 11:56:30 +01:00
- name: Build package
2022-02-07 16:06:11 +01:00
run: nix build -L .#"${{ matrix.name }}"
2022-01-18 11:56:32 +01:00
build-configs:
name: NixOS configs
2022-01-18 11:56:32 +01:00
runs-on: ubuntu-latest
needs: [ build-pkgs ]
strategy:
2022-03-24 17:22:02 +01:00
fail-fast: false
2022-01-18 11:56:32 +01:00
matrix:
name:
- boreal
2022-06-10 18:01:58 +02:00
- hades
2024-03-03 01:57:24 +01:00
- talos
2023-12-13 17:29:54 +01:00
- thanatos
2022-01-18 11:56:32 +01:00
steps:
2023-11-15 12:01:30 +01:00
- uses: actions/checkout@v4
2022-01-18 11:56:32 +01:00
2024-02-06 17:54:03 +01:00
- uses: cachix/install-nix-action@v25
2022-01-18 11:56:32 +01:00
2024-02-06 17:54:03 +01:00
- uses: cachix/cachix-action@v14
2022-01-18 11:56:32 +01:00
with:
name: alarsyo
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}'
extraPullNames: "nix-community"
- name: Build package
2022-02-07 16:06:11 +01:00
run: nix build -L .#nixosConfigurations."${{ matrix.name }}".config.system.build.toplevel