Config files for my server. Except not my secrets
1#!/usr/bin/env bash 2 3echo "\n\nGot new commit: $(date)\n---\n\n" 4 5# pull latest version 6echo "git fetch --all" 7git fetch --all 8echo "git reset --hard origin/master" 9git reset --hard origin/master 10 11echo "curl -d fetched-latest http://compuper:6500/notify" 12cat <<BODY | curl -d @- http://compuper:6500/notify 13name=vps%3A%20git%20($(git log -1 --pretty=format:%h)) 14&timeout=5000 15&body=fetched%20latest%20git%20commit%20for%20vielle.dev/vps-config 16&key=vps/commit/git 17BODY 18 19# restart/rebuild all containers 20echo "docker compose build --no-cache" 21docker compose build --no-cache 22echo "docker compose up -d --force-recreate" 23docker compose up -d --force-recreate 24 25# clear out dockerfiles to stop my drive exploding 26echo "docker system prune -af > /dev/null" 27docker system prune -af > /dev/null 28 29echo "curl -d ready http://compuper:6500/notify" 30cat <<- BODY | curl -d @- http://compuper:6500/notify 31name=vps%3A%20ready%20($(git log -1 --pretty=format:%h))\ 32&timeout=5000 33&body=finished%20building%20docker 34&key=vps/commit/build 35BODY 36 37exit 0