Initial homelab workspace structure
This commit is contained in:
parent
041047601a
commit
2b5d59ae27
0
scripts/bootstrap.sh
Executable file
0
scripts/bootstrap.sh
Executable file
0
scripts/deploy/deploy-host.sh
Executable file
0
scripts/deploy/deploy-host.sh
Executable file
21
scripts/deploy/deploy-role.sh
Executable file
21
scripts/deploy/deploy-role.sh
Executable file
|
|
@ -0,0 +1,21 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
ROLE=$1
|
||||||
|
HOST=$2
|
||||||
|
|
||||||
|
if [ -z "$ROLE" ] || [ -z "$HOST" ]; then
|
||||||
|
echo "Usage:"
|
||||||
|
echo "./deploy-role.sh <role> <host>"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Deploying role: $ROLE to host: $HOST"
|
||||||
|
|
||||||
|
ssh $HOST "
|
||||||
|
mkdir -p ~/homelab-codex-ws &&
|
||||||
|
cd ~/homelab-codex-ws &&
|
||||||
|
git pull &&
|
||||||
|
docker compose -f roles/$ROLE/compose/docker-compose.yml up -d
|
||||||
|
"
|
||||||
0
scripts/deploy/update-all.sh
Executable file
0
scripts/deploy/update-all.sh
Executable file
Loading…
Reference in a new issue