ci: try to improve disk space #521
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: "Cachix" | |
on: | |
push: | |
paths: | |
- '**.nix' | |
- '**.age' | |
- 'pkgs/**' | |
- 'flake.nix' | |
- 'flake.lock' | |
- '.github/workflows/cachix.yaml' | |
jobs: | |
format-check: | |
name: Format check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@v27 | |
- name: Run alejandra | |
run: nix develop --command alejandra --check . | |
flake-check: | |
name: Flake check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@v27 | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: alarsyo | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
extraPullNames: "nix-community" | |
- name: Build package | |
run: nix flake check | |
build-pkgs: | |
name: Nix packages | |
runs-on: ubuntu-latest | |
needs: [ flake-check, format-check ] | |
strategy: | |
fail-fast: false | |
matrix: | |
name: | |
- grafanaDashboards/nginx | |
- grafanaDashboards/node-exporter | |
- kaleidoscope-udev-rules | |
- sddm-sugar-candy | |
- spot | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@v27 | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: alarsyo | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
extraPullNames: "nix-community" | |
- name: Build package | |
run: nix build -L .#"${{ matrix.name }}" | |
build-configs: | |
name: NixOS configs | |
runs-on: ubuntu-latest | |
needs: [ build-pkgs ] | |
strategy: | |
fail-fast: false | |
matrix: | |
name: | |
- boreal | |
- hades | |
- talos | |
- thanatos | |
steps: | |
- name: Delete huge unnecessary tools folder | |
run: rm -rf /opt/hostedtoolcache | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@v27 | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: alarsyo | |
authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' | |
extraPullNames: "nix-community" | |
- name: Build package | |
run: nix build -L .#nixosConfigurations."${{ matrix.name }}".config.system.build.toplevel |