Build machine config change and fixes, improve the dry running, move about the some configs when using builtin hardware-configuration.nix, and fix some syntax issues.

This commit is contained in:
Root User 2026-02-12 17:37:54 +01:00
parent c7d4fc7e47
commit 3ac51c3662
Signed by: root
GPG key ID: 087F0A95E5766D72
4 changed files with 31 additions and 59 deletions

View file

@ -1,3 +1,4 @@
#!/usr/bin/env zsh
export NIX_CONFIG="experimental-features = nix-command flakes"
@ -5,13 +6,23 @@ echo "=== nix --version ==="
nix --version
echo
echo "=== nix flake show ==="
nix flake show .
echo
configs=(
"nixos-local-wireguard-server"
"nixos-blank"
"nixos-songsheet"
"nixos-database"
"nixos-forgejo"
"nixos-teamspeak"
"nixos-traefik"
"nixos-build-machine"
)
echo "=== nix eval (raw toplevel) ==="
nix eval --raw .#nixosConfigurations.nixos-local-wireguard-server.config.system.build.toplevel || true
echo
if [[ -n "$1" ]]; then
configs=("$1")
fi
echo "=== nix build --dry-run ==="
nix build --dry-run .#nixosConfigurations.nixos-local-wireguard-server.config.system.build.toplevel || true
for config in "${configs[@]}"; do
echo "=== Dry-run: $config ==="
nix build --dry-run ".#nixosConfigurations.${config}.config.system.build.toplevel" || true
echo
done