diff --git a/scripts/install.sh b/scripts/install.sh index 0372cf7..6976bd7 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -57,12 +57,23 @@ cp "$KEYDIR/host" "$dir/ssh_host_ed25519_key" cp "$KEYDIR/host.pub" "$dir/ssh_host_ed25519_key.pub" chmod 600 "$dir/ssh_host_ed25519_key" -# run disko-install +# run disko +ROOT_MNT="/mnt" cp "$KEYDIR/luks-pw" "/tmp/luks-pw" -disko-install \ - --extra-files "$temp" "/" \ +disko \ + --mode disko \ --flake .#$NAME \ - --write-efi-boot-entries + --root-mountpoint $ROOT_MNT + +# copy extra files into mountpoint +cp -r "$temp" "$ROOT_MNT/" + +# run nixos-install +nixos-install \ + --no-channel-copy \ + --no-root-password \ + --root "$ROOTMNT" \ + --flake .#$NAME echo -e "Finished install.\n" \ "Make sure to delete the SSH host keys from here if you are done with them."