Files
mtusi2026lab4/scripts/restart.cmd
T

12 lines
475 B
Batchfile

@echo off
setlocal
cd /d "%~dp0.."
if "%COMPOSE_ENV_FILE%"=="" set COMPOSE_ENV_FILE=.env
echo restart: restarting API, PostgreSQL, Valkey and S3 (volumes preserved)
rem The resilience test owns readiness waiting; s3-init has already created bucket.
docker compose --env-file %COMPOSE_ENV_FILE% restart --timeout 15 postgres valkey s3 api-1 api-2 nginx
if errorlevel 1 exit /b 1
docker compose --env-file %COMPOSE_ENV_FILE% ps
echo stack_restarted volumes_preserved
exit /b 0