chore: add production deploy script
Authored-By: Jack Levy
This commit is contained in:
18
deploy.sh
Normal file
18
deploy.sh
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# PocketVeto — production deploy script
|
||||||
|
# Run on the server: ./deploy.sh
|
||||||
|
# Run from laptop: ssh user@server 'bash /opt/civicstack/deploy.sh'
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
REPO_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||||
|
|
||||||
|
echo "==> Pulling latest from main..."
|
||||||
|
cd "$REPO_DIR"
|
||||||
|
git pull origin main
|
||||||
|
|
||||||
|
echo "==> Rebuilding and restarting containers..."
|
||||||
|
docker compose -f docker-compose.yml -f docker-compose.prod.yml up -d --build
|
||||||
|
|
||||||
|
echo "==> Done. Running containers:"
|
||||||
|
docker compose ps
|
||||||
Reference in New Issue
Block a user