37 lines
866 B
YAML
37 lines
866 B
YAML
name: Check NixOS Config
|
|
|
|
on:
|
|
pull_request:
|
|
push:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Install Nix
|
|
uses: cachix/install-nix-action@v27
|
|
with:
|
|
nix_path: nixpkgs=channel:nixos-unstable
|
|
extra_nix_config: |
|
|
experimental-features = nix-command flakes
|
|
accept-flake-config = true
|
|
|
|
- name: Setup Cachix
|
|
uses: cachix/cachix-action@v15
|
|
with:
|
|
name: chexit
|
|
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
|
|
|
|
- name: Check flake syntax
|
|
run: nix flake check --no-build
|
|
|
|
- name: Build system config
|
|
run: |
|
|
nix build .#nixosConfigurations.chexit.config.system.build.toplevel \
|
|
--no-link \
|
|
--print-build-logs |