@echo off rem Windows equivalent of stop-one.sh: stop exactly one API replica and leave it stopped. setlocal if "%TARGET_INSTANCE_ID%"=="" ( echo test provides target API instance alias 1>&2 exit /b 2 ) if /i not "%TARGET_INSTANCE_ID%"=="api1" if /i not "%TARGET_INSTANCE_ID%"=="api2" ( echo unexpected API instance alias 1>&2 exit /b 2 ) docker stop lab4-%TARGET_INSTANCE_ID% >nul if errorlevel 1 exit /b 1 exit /b 0