I’m trying to build my Nix configuration in GitLab CI, to make sure any changes have at least a chance of working in NixOS. The official Nix Docker image has a very different structure from NixOS (being based on Alpine), and I keep getting an error I’ve no idea how to resolve:
$ docker run --volume=$(pwd):/etc/nixos --interactive --rm --tty nixos/nix 5cc8dad8d887:/# nix-build /etc/nixos/configuration.nix error: cannot auto-call a function that has an argument without a default value ('config')
Even the file generated by
nixos-generate-config has the same problem:
$ cd "$(mktemp --directory)" $ nixos-generate-config --root . $ nix-build etc/nixos/configuration.nix error: cannot auto-call a function that has an argument without a default value ('config')
The only other repo I’ve found to do something similar is much more complex than what I was hoping to do here.