Files
bash-scripts/nixos/update.sh
2026-03-28 17:34:25 -04:00

20 lines
589 B
Bash
Executable File

#!/usr/bin/env bash
update() {
cd ~/dotfiles
git pull
git submodule init
git submodule update
sudo nixos-rebuild switch --flake ~/dotfiles
home-manager switch --flake ~/dotfiles
}
# Nixos VMs
ssh media@media.randomctf.com -t "$(typeset -f update); update"
ssh logging@logging.randomctf.local -t "$(typeset -f update); update"
ssh mindforge@mindforge.randomctf.local -t "$(typeset -f update); update"
ssh mnemosyne@mnemosyne.randomctf.local -t "$(typeset -f update); update"
# Ubuntu VMs
ssh pbx@pbx.randomctf.local -t "sudo apt update -y && sudo apt upgrade -y"