forked from mtusi2026/mtusi2026lab5
Реализовать lab5 на оценку 4: async attachments, outbox, worker и variants.
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
@echo off
|
||||
setlocal EnableExtensions
|
||||
cd /d "%~dp0\.."
|
||||
if "%TARGET_INSTANCE_ID%"=="" (
|
||||
echo stop-one: TARGET_INSTANCE_ID required >&2
|
||||
exit /b 1
|
||||
)
|
||||
for /f "usebackq delims=" %%I in (`docker compose --env-file .env ps -q api`) do (
|
||||
for /f "usebackq delims=" %%H in (`docker inspect -f "{{.Config.Hostname}}" %%I`) do (
|
||||
if /I "%%H"=="%TARGET_INSTANCE_ID%" (
|
||||
docker stop -t 15 %%I >nul
|
||||
exit /b 0
|
||||
)
|
||||
)
|
||||
)
|
||||
echo stop-one: replica not found >&2
|
||||
exit /b 1
|
||||
Reference in New Issue
Block a user