Commit graph

269 commits

Author SHA1 Message Date
Yohta Kimura
cdaeeac6ed 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) <noreply@anthropic.com>
Signed-off-by: Yohta Kimura <38206553+rajyan@users.noreply.github.com>
2026-06-23 15:01:33 +02:00
Yohta Kimura
5c9d611b5f Handle rawsetenv collisions with overwrite and warning
rawsetenv injects provider variables without the service-name prefix, so
a key can collide with a value already set on the dependent service,
whether declared by the user in environment or emitted by another
provider. Log a warning and overwrite on collision, document the
precedence and the non-deterministic ordering between concurrent
providers, and cover the user-environment override with an e2e test.

Signed-off-by: Yohta Kimura <38206553+rajyan@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-23 15:01:33 +02:00
Yohta Kimura
332e0add14 Add rawsetenv message type for provider plugins
Providers can now send rawsetenv messages to inject environment
variables into dependent services without the automatic service name
prefix. This enables use cases where applications require exact
variable names that cannot be altered.

Closes #13727

Signed-off-by: Yohta Kimura <38206553+rajyan@users.noreply.github.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-06-23 15:01:33 +02:00
Sebastiaan van Stijn
39ee1d02b6 docs: compose logs: add more links for flag descriptions
Some checks failed
ci / validate (lint) (push) Has been cancelled
ci / validate (validate-docs) (push) Has been cancelled
ci / validate (validate-go-mod) (push) Has been cancelled
ci / validate (validate-headers) (push) Has been cancelled
ci / binary (push) Has been cancelled
ci / bin-image-test (push) Has been cancelled
ci / test (push) Has been cancelled
ci / e2e (plugin, oldstable) (push) Has been cancelled
ci / e2e (standalone, oldstable) (push) Has been cancelled
ci / e2e (plugin, stable) (push) Has been cancelled
ci / e2e (standalone, stable) (push) Has been cancelled
docs-upstream / docs-yaml (push) Has been cancelled
merge / bin-image-prepare (push) Has been cancelled
merge / module-image (push) Has been cancelled
Scorecards supply-chain security / Scorecards analysis (push) Has been cancelled
ci / binary-finalize (push) Has been cancelled
ci / coverage (push) Has been cancelled
ci / release (push) Has been cancelled
docs-upstream / validate (push) Has been cancelled
merge / bin-image (push) Has been cancelled
merge / desktop-edge-test (push) Has been cancelled
follow-up to 7eeb7de7a2, adding more
links now that the CLI reference for docker logs has anchors for them.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-06-10 09:36:31 +02:00
Sebastiaan van Stijn
7eeb7de7a2 docs: compose logs: add links for since/until flag descriptions
Some checks failed
ci / validate (lint) (push) Has been cancelled
ci / validate (validate-docs) (push) Has been cancelled
ci / validate (validate-go-mod) (push) Has been cancelled
ci / validate (validate-headers) (push) Has been cancelled
ci / binary (push) Has been cancelled
ci / bin-image-test (push) Has been cancelled
ci / test (push) Has been cancelled
ci / e2e (plugin, oldstable) (push) Has been cancelled
ci / e2e (standalone, oldstable) (push) Has been cancelled
ci / e2e (plugin, stable) (push) Has been cancelled
ci / e2e (standalone, stable) (push) Has been cancelled
docs-upstream / docs-yaml (push) Has been cancelled
merge / bin-image-prepare (push) Has been cancelled
merge / module-image (push) Has been cancelled
Scorecards supply-chain security / Scorecards analysis (push) Has been cancelled
ci / binary-finalize (push) Has been cancelled
ci / coverage (push) Has been cancelled
ci / release (push) Has been cancelled
docs-upstream / validate (push) Has been cancelled
merge / bin-image (push) Has been cancelled
merge / desktop-edge-test (push) Has been cancelled
Link to the corresponding `docker container logs` equivalents, which
contain more details on the accepted formats and use.

The container logs documentation still needs some updates to provide
per-flag sections, so follow-ups can be made once those are done.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2026-05-26 14:28:34 +02:00
Guillaume Lours
19fc292eb9 perf: avoid duplicate provider metadata fetch on stop
The previous implementation fetched the provider binary path and
metadata twice per service during `compose stop`: once in stop.go
to gate on the `stop` capability, and again inside runPlugin via
setupPluginCommand.

setupPluginCommand now signals "skip" by returning (nil, nil) when
the requested command is absent from the provider's metadata.
stop.go calls runPlugin directly; the skip-when-unadvertised check
moves into runPlugin.

Addresses PR #13779 review feedback.

Signed-off-by: Guillaume Lours <glours@users.noreply.github.com>
2026-05-18 11:11:38 +02:00
Guillaume Lours
672dc14d29 feat: add stop lifecycle hook for external providers
Provider-backed services were silently skipped on `docker compose stop`,
leaving external resources running after the user expected the stack to
be paused (e.g. after Ctrl+C during `up --watch`).

Compose now invokes `<provider> compose stop <service>` for providers
that advertise a `stop` block in their `metadata` subcommand output.
Providers that do not advertise stop (or do not implement metadata at
all) are silently skipped, preserving backward compatibility with
existing providers that pre-date this hook.

Closes #13772

Signed-off-by: Guillaume Lours <glours@users.noreply.github.com>
2026-05-18 11:11:38 +02:00
Ryan Bonnell
b8effbacb5 Change verb tense in compose command documentation
Signed-off-by: Ryan Bonnell <ryanjbonnell@gmail.com>
2026-05-06 21:02:56 +02:00
Adam Sven Johnson
63ae7eb0fa Replace tabbed indentation in sdk.md
Tabs and spaces were mixed in the example code which didn't indent cleanly in the github preview.

Signed-off-by: Adam Sven Johnson <adam@pkqk.net>
2026-01-14 07:56:25 +01:00
Rashmi Vagha
85ea24b62c Fix grammar: pluralize 'service' and remove apostrophes in lets
Signed-off-by: Rashmi Vagha <rvagha@umass.edu>
2025-12-05 10:33:35 +01:00
Nicolas De Loof
cfcee45a89 fix SDK example
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-12-03 16:55:23 +01:00
Sebastiaan van Stijn
dc66e6bad1 golangci-lint: use gci formatter instead of goimports
Most files already grouped imports into "stdlib -> other -> local",
but some files didn't. The gci formatter is similar to goimports, but
has better options to make sure imports are grouped in the expected
order (and to make sure no additional groups are present).

This formatter has a 'fix' function, so code can be re-formatted auto-
matically;

    golangci-lint run -v --fix

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-12-01 12:21:50 +01:00
Nicolas De Loof
b32297dccd add --wait option to start command
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-12-01 11:58:00 +01:00
Nicolas De Loof
2b4543935c next release will be major version v5.x
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-11-13 09:32:43 +01:00
aevesdocker
f0dce1b977 sdk docs: patch
Signed-off-by: aevesdocker <allie.sadler@docker.com>
2025-11-12 16:24:24 +01:00
Nicolas De Loof
9de7e2a388 SDK docs
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-11-10 16:15:36 +01:00
Nicolas De Loof
7eb5adeef6 introduce --insecure-registry, reserved for testing purpose
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-11-06 16:17:21 +01:00
Nicolas De Loof
0793ad7c68 document support for OCI and Git remote resources
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-11-06 16:14:05 +01:00
Anton Ovchinnikov
8619f5d72a Fix help output for "exec --no-tty" option
Signed-off-by: Anton Ovchinnikov <anton@tonyo.info>
2025-10-23 18:19:41 +02:00
Nicolas De Loof
07602f2070 publish Compose application as compose.yaml + images
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-10-03 10:59:57 +02:00
Nicolas De loof
c75418ee07 Apply suggestions from code review
Co-authored-by: Allie Sadler <102604716+aevesdocker@users.noreply.github.com>
Signed-off-by: Nicolas De loof <nicolas.deloof@gmail.com>
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-09-08 15:56:55 +02:00
Nicolas De Loof
b768232c0e document (hidden) --tty --interactive flags
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-09-08 15:56:55 +02:00
Nicolas De Loof
fd954f266c show build progress during watch rebuild
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-07-23 13:57:46 +02:00
Nicolas De Loof
8f91793fb5 introduce build.provenance and sbom support
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-07-21 17:07:41 +02:00
MohammadHasan Akbari
f42226e352 feat: add --models flag to config command
Signed-off-by: MohammadHasan Akbari <jarqvi.jarqvi@gmail.com>
2025-07-11 11:08:08 +02:00
MohammadHasan Akbari
35efa97b7d feat: add since & until flags to events command
Signed-off-by: MohammadHasan Akbari <jarqvi.jarqvi@gmail.com>
Co-authored-by: Amin Ehterami <A.Ehterami@proton.me>
2025-07-09 10:08:33 +02:00
MohammadHasan Akbari
66524e7728 feat: add --networks flag to config command
Signed-off-by: MohammadHasan Akbari <jarqvi.jarqvi@gmail.com>
2025-07-07 10:37:20 +02:00
Leonardo Peregrino
63b441401e add volumes docs/reference/
Signed-off-by: Leonardo Peregrino <55335068+leoperegrino@users.noreply.github.com>
2025-06-30 19:38:27 +02:00
Guillaume Lours
5a063b7510 fix provider concurrent environment map accesses
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-06-30 19:07:10 +02:00
Guillaume Lours
40f5786e68 add support of metadata subcommand for provider services
This command will let Compose and external tooling know about which parameters should be passed to the Compose plugin

Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-06-05 15:12:32 +02:00
Nicolas De Loof
693b9ef078 fix support for BUILDKIT_PROGRESS
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-06-02 11:03:04 +02:00
Guillaume Lours
9a9227ce64 add new bridge commands documentation
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-05-27 10:35:30 +02:00
Guillaume Lours
bbb2b76a14 bump cli-doc-tools to v0.10.0
and update the documentation to pass CI checks

Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-05-26 16:37:45 +02:00
Nicolas De Loof
8a2cb90a39 example provider implementation
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-05-21 15:59:30 +02:00
Guillaume Lours
7e198ee6a3 remove provenance build flag for now
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-05-20 18:21:05 +02:00
Guillaume Lours
0566431c64 only use attestation when building image outside the development inner loop
when building a image, by default attestation are generated and modify the image ID which trigger a container recreation on up, run command even if there isn't any changes on the image content itself

Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-05-20 18:21:05 +02:00
Nicolas De Loof
2352a4a016 introduce config --lock-image-digests
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-05-19 13:53:01 +02:00
Guillaume Lours
009a239510 remove convert alias from config command
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-05-19 12:30:09 +02:00
Guillaume Lours
4dcaf94c32 add support of 'debug' messages in the communication between Compose and provider binaries
Signed-off-by: Guillaume Lours <705411+glours@users.noreply.github.com>
2025-05-13 18:32:03 +02:00
Alessio Perugini
4bf18d2325 docs: regenerate
Signed-off-by: Alessio Perugini <alessio@perugini.xyz>
2025-05-06 22:33:52 +02:00
Nicolas De Loof
16e83f002d introduce build --check
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-05-06 07:54:30 +02:00
Nicolas De Loof
2dbef234dc document behavior on missing extension
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-05-05 14:33:35 +02:00
Nicolas De Loof
20f0ffec0b seach for provider binary in PATH
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-05-05 11:21:21 +02:00
Nicolas De Loof
cee6a3c660 document extensibility using service.provider
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-05-05 11:21:21 +02:00
Suleiman Dibirov
b543380708 feat(run): Add --quiet and --quiet-build options for the run command
Signed-off-by: Suleiman Dibirov <idsulik@gmail.com>
2025-04-03 14:50:38 +02:00
k-kbk
ec49db98d4 fix: replace docker-compose.yml with compose.yaml
Signed-off-by: k-kbk <kkbk0077@gmail.com>
2025-03-27 15:44:00 +01:00
k-kbk
e5a353b34d fix: replace docker-compose.yml with compose.yaml
Signed-off-by: k-kbk <kkbk0077@gmail.com>
2025-03-27 15:44:00 +01:00
Nicolas De Loof
75368c7859 introduce build --print to dump equivalent bakefile
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-03-26 12:24:31 +01:00
Nicolas De Loof
a0d1c3f944 introduce config --no-env-resolution
Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
2025-03-24 15:46:04 +01:00
Remco Kranenburg
b0badf1eb0 Set watch option --prune=true as default
Signed-off-by: Remco Kranenburg <remco.kranenburg@crunchr.com>
2025-03-19 17:48:05 +01:00