diff --git a/Sovran_SystemsOS_Updater/Updater Source Files/Update_Sovran_SystemsOS.sh b/Sovran_SystemsOS_Updater/Updater Source Files/Update_Sovran_SystemsOS.sh index ee81414..26028f2 100755 --- a/Sovran_SystemsOS_Updater/Updater Source Files/Update_Sovran_SystemsOS.sh +++ b/Sovran_SystemsOS_Updater/Updater Source Files/Update_Sovran_SystemsOS.sh @@ -14,7 +14,9 @@ if [[ $? -eq 1 ]]; then else -ssh -i /home/free/.ssh/sovranpro_login root@192.168.1.32 'cd /etc/nixos; nix flake update' +id=(curl ifconfig.me || ifdata -pa enp2s0 || ifdata -pa wlp1s0) + +ssh -i /home/free/.ssh/sovranpro_login root@${id} 'cd /etc/nixos; nix flake update' if [[ $? != 0 ]]; then echo "Could not update flake -- exiting" | @@ -26,7 +28,7 @@ if [[ $? != 0 ]]; then exit 1 fi -ssh -i /home/free/.ssh/sovranpro_login root@192.168.1.32 "nixos-rebuild switch --impure" | +ssh -i /home/free/.ssh/sovranpro_login root@${id} "nixos-rebuild switch --impure" | zenity --progress \ --no-cancel \ --auto-close \