19 lines
392 B
Bash
19 lines
392 B
Bash
|
#/usr/bin/env sh
|
||
|
|
||
|
# Build a NixOS VM for testing
|
||
|
#
|
||
|
# For x86_64 hosts: use curacao config
|
||
|
# For aarch64 hosts: use pindakaas config
|
||
|
|
||
|
export NIXPKGS_ALLOW_UNFREE=1
|
||
|
if [ "$(uname -m)" == "x86_64" ]
|
||
|
then
|
||
|
config=./curacao.nix
|
||
|
elif [ "$(uname -m)" == "aarch64" ]
|
||
|
then
|
||
|
config=./pindakaas.nix
|
||
|
fi
|
||
|
nix-build '<nixpkgs/nixos>' -A vm \
|
||
|
-I nixpkgs=channel:nixos-23.05 \
|
||
|
-I nixos-config=${config}
|