Portal/scripts/prod/UpdateProd.sh
Ivan 679eefcd38
Some checks failed
Backend CI / build (3.12) (push) Has been cancelled
Frontend CI / build (22.x) (push) Has been cancelled
Backend CI / notify-failure (push) Has been cancelled
Frontend CI / notify-failure (push) Has been cancelled
M: Add restart after rebuild
2025-07-17 19:33:22 +03:00

16 lines
450 B
Bash

COMPOSE_FILE="docker-compose-prod.yml"
BACKUP_SCRIPT="./scripts/prod/CreateBackup.sh"
git fetch --all
git reset --hard origin/main
/bin/bash "${BACKUP_SCRIPT}"
docker compose --file "${COMPOSE_FILE}" up --build --detach
docker compose --file "${COMPOSE_FILE}" restart
# Use this to prune caches
# docker system prune -a -f
# Use this command to restart containers if something went wrong
# docker compose --file "docker-compose-prod.yml" restart