aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2020-08-11 09:41:58 -0300
committerEuAndreh <eu@euandre.org>2020-08-11 09:42:15 -0300
commit57dfc5fd9ba6523079e3ca288b2802f8774f1fc1 (patch)
tree3f3057d986238117ae7c13a876de3ffb84138a84
parentnixos-update.sh: Remove /tmp/tmp.nix files and pipe directly into file (diff)
downloadtoph-57dfc5fd9ba6523079e3ca288b2802f8774f1fc1.tar.gz
toph-57dfc5fd9ba6523079e3ca288b2802f8774f1fc1.tar.xz
nixos-update.sh: Always set the NixOS channel based on $SYSTEM_STATE_VERSION
-rwxr-xr-xnixos-update.sh1
-rw-r--r--secrets/secret-envrc.shbin3975 -> 4055 bytes
2 files changed, 1 insertions, 0 deletions
diff --git a/nixos-update.sh b/nixos-update.sh
index 8919a99..856acb4 100755
--- a/nixos-update.sh
+++ b/nixos-update.sh
@@ -5,4 +5,5 @@ set -Eeuo pipefail
cd "$(dirname "${BASH_SOURCE[0]}")"
cat <(echo "${USER_PASSWORD}") <(envsubst < vps-configuration.env.nix) | ssh "$TLD" sudo -S 'cat > /etc/nixos/configuration.nix'
+echo "${USER_PASSWORD}" | ssh "$TLD" sudo -S nix-channel --add "https://nixos.org/channels/nixos-${SYSTEM_STATE_VERSION}" nixos
echo "${USER_PASSWORD}" | ssh "$TLD" sudo -S -i nixos-rebuild switch --upgrade
diff --git a/secrets/secret-envrc.sh b/secrets/secret-envrc.sh
index 764a96c..33ca8e6 100644
--- a/secrets/secret-envrc.sh
+++ b/secrets/secret-envrc.sh
Binary files differ