improved organisation

moved host modules to hosts/modules and modified deploy script
This commit is contained in:
Emile Clark-Boman 2025-02-24 13:19:36 +10:00
parent 9636eab7f6
commit c3b02c5f7b
18 changed files with 27 additions and 20 deletions

16
deploy
View file

@ -6,6 +6,7 @@ usage="Usage: $(basename $0) [OPTIONS]
Options:
-f, --fresh Remove old content in the nixstore (good for debugging)
-b, --bootloader Reinstall the bootloader
-r, --remote Locally build and remotely deploy Colmena hive
-h, --help Show this message (^_^)"
# delete all cached entries
@ -25,11 +26,26 @@ rebuild_flake () {
fi
}
deploy_hive () {
echo "[+] Adding keys to ssh-agent"
ssh-add ~/.ssh/id_hyrule
printf "\n"
git add . --verbose
# Deploy to all Colmena hives
colmena build --experimental-flake-eval
colmena apply --experimental-flake-eval
# colmena apply --on hyrule --experimental-flake-eval
}
# check which flags were given
flag_fresh=false
flag_bootloader=false
for flag in "$@"; do
case "$flag" in
-r|--remote)
deploy_hive
exit 0 ;;
-f|--fresh)
flag_fresh=true ;;
-b|--bootloader)