diff --git a/docs/specs/sf-self-deploy.md b/docs/specs/sf-self-deploy.md index f84a9f1f0..2738c76bf 100644 --- a/docs/specs/sf-self-deploy.md +++ b/docs/specs/sf-self-deploy.md @@ -81,7 +81,7 @@ web host, writes the release manifest, starts `sf-server-vega-candidate` on port 4001, probes health/readiness/version/projects, replaces `sf-server-vega` on port 4000 only after the candidate passes, probes prod, then removes the candidate. Replacement drains the old container with -`docker stop --timeout ${SF_VEGA_DRAIN_STOP_TIME:-610}` before forced removal +`docker stop -t ${SF_VEGA_DRAIN_STOP_TIME:-610}` before forced removal fallback. The default leaves a 10 second margin over the RPC child's `SF_RPC_SHUTDOWN_GRACE_MS=600000` queue-drain handler. diff --git a/scripts/run-vega-source-server.mjs b/scripts/run-vega-source-server.mjs index a47096df0..3fa6a82a6 100644 --- a/scripts/run-vega-source-server.mjs +++ b/scripts/run-vega-source-server.mjs @@ -208,7 +208,7 @@ function socketGroupId(path) { function drainContainer(containerName) { if (!containerExists(containerName)) return; const stopTime = process.env.SF_VEGA_DRAIN_STOP_TIME || "610"; - run("docker", ["stop", "--timeout", stopTime, containerName], { + run("docker", ["stop", "-t", stopTime, containerName], { allowFailure: true, }); run("docker", ["rm", "-f", containerName], { allowFailure: true }); diff --git a/scripts/upgrade-vega-source-server.mjs b/scripts/upgrade-vega-source-server.mjs index 0d77b950a..715c7f760 100644 --- a/scripts/upgrade-vega-source-server.mjs +++ b/scripts/upgrade-vega-source-server.mjs @@ -201,7 +201,7 @@ function drainContainer(name) { // lock contention so queued self-feedback writes are never lost // across an upgrade. Override per-deployment via env if needed. const stopTime = process.env.SF_VEGA_DRAIN_STOP_TIME || "610"; - run("docker", ["stop", "--timeout", stopTime, name], { allowFailure: true }); + run("docker", ["stop", "-t", stopTime, name], { allowFailure: true }); run("docker", ["rm", "-f", name], { allowFailure: true }); }