From cdaeeac6edc6a255adb7770c7b0d972615dca4ea Mon Sep 17 00:00:00 2001 From: Yohta Kimura <38206553+rajyan@users.noreply.github.com> Date: Tue, 23 Jun 2026 10:14:48 +0900 Subject: [PATCH] Document rawsetenv in stop section and sequence diagram The stop section only mentioned setenv being ignored; rawsetenv is handled identically by the code but was missing from the docs. The mermaid sequence diagram also lacked a rawsetenv step. Co-Authored-By: Claude Opus 4.6 (1M context) Signed-off-by: Yohta Kimura <38206553+rajyan@users.noreply.github.com> --- docs/extension.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/extension.md b/docs/extension.md index 1234a3b93..268f56cc0 100644 --- a/docs/extension.md +++ b/docs/extension.md @@ -72,6 +72,8 @@ sequenceDiagram Compose-)Shell: pulling 75% Provider--)Compose: json { "setenv": "URL=http://cloud.com/abcd:1234" } Compose-)Compose: set DATABASE_URL + Provider--)Compose: json { "rawsetenv": "SECRET_KEY=xxx" } + Compose-)Compose: set SECRET_KEY (as-is) Provider-)Compose: EOF (command complete) exit 0 Compose-)Shell: service started ``` @@ -128,7 +130,7 @@ The provider is responsible for releasing all resources associated with the serv When the user runs `docker compose stop`, Compose invokes ` compose --project-name stop ` for each provider-backed service in reverse dependency order. The provider should pause the resource without releasing it, so a later `docker compose up` can resume it (note that `docker compose start` only restarts existing containers and does not invoke -provider hooks). Any `setenv` JSON message returned during `stop` is ignored, since dependent services are also stopping. +provider hooks). Any `setenv` or `rawsetenv` JSON message returned during `stop` is ignored, since dependent services are also stopping. The `stop` hook is opt-in: Compose invokes it only when the provider declares a `stop` block in its `metadata` subcommand output. Providers that do not advertise `stop` in metadata (or do not implement the `metadata` subcommand at all) are