deploy: archive after an update

This commit is contained in:
Aaron Bieber 2024-10-01 08:00:59 -06:00
parent 81046c56a7
commit b58e70e76c
No known key found for this signature in database

View File

@ -10,10 +10,8 @@ rebuild() {
host="$(resolveAlias $1)"
skip_check=$2
msg "Rebuilding: ${host}"
set -x
build_host=${BUILD_HOST:-$host}
msg "Rebuilding: ${host} using ${build_host}"
nixos-rebuild ${TRACE} --flake .#${1} --build-host "root@${build_host}" --target-host "root@${host}" switch 2>&1 | nom
return $?
}
@ -119,17 +117,17 @@ if [ "$1" = "update" ]; then
done
# TODO: capture commit message and wrap it with what is being updated.
if [ $can_sign = 1 ]; then
if [ $can_sign != 1 ]; then
echo "Can't find signing key."
exit 1
fi
if [ "$single" != "" ]; then
nix flake update --commit-lock-file "$single"
else
nix flake update --commit-lock-file
fi
exit
else
echo "Can't find signing key."
exit 1
fi
nix flake archive
fi
if [ "$1" = "installer" ]; then