nixos/.gitlab-ci.yml

23 lines
496 B
YAML

image: nixos/nix:latest
before_script:
- echo "extra-experimental-features = nix-command flakes" >> /etc/nix/nix.conf
- nix-daemon &
nix-flake-check:
timeout: 1h
stage: test
script:
- nix flake check --no-build
# Adapted from https://cobalt.rocks/posts/nix-update/ AGPLv3+
nix-flake-update:
stage: build
script:
- nix run .#update-flake
rules:
- if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH && $CI_PIPELINE_SOURCE == "schedule"
variables:
GIT_STRATEGY: clone