compose/cmd/compose
Guillaume Lours 0aff61809c run: trigger a job through the engine like a service
`docker compose run <job>` triggers a run of the job on the engine,
starts its dependencies first, streams its logs and returns its exit
code like a one-off service; a job accepts manual triggering unless it
declares manual: false. A scheduled job runs as up registered it: an
override, or a job up never registered, is refused. A manual job is
removed from the engine after its run, so the next run can differ. When
the engine cannot run jobs, run falls back to a one-off service with a
warning. --detach is refused, an interrupted run is cancelled, a dry run
only reports it. A job named by create, start, build, pull or push gets
an error naming run instead.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Signed-off-by: Guillaume Lours <glours@users.noreply.github.com>
2026-11-17 13:48:57 +01:00
..
alpha.go chore: remove duplicate 'publish' registration under 'alpha' 2026-09-30 14:47:12 +02:00
attach.go build(lint): enable the dupl linter 2026-10-29 11:59:43 +01:00
backend.go refactor: fix lint issues from cleanup changes 2026-05-12 11:31:40 +02:00
bridge.go fix(bridge): reject --dry-run on bridge commands 2026-10-08 16:49:40 +02:00
bridge_test.go fix(bridge): reject --dry-run on bridge commands 2026-10-08 16:49:40 +02:00
build.go run: trigger a job through the engine like a service 2026-11-17 13:48:57 +01:00
build_test.go fix(build): hand unresolved 'auto' progress mode to bake 2026-09-07 14:11:12 +02:00
commit.go golangci-lint: use gci formatter instead of goimports 2025-12-01 12:21:50 +01:00
completion.go feat(compose): warn on unsupported compose-file attributes 2026-09-09 16:32:04 +02:00
compose.go run: trigger a job through the engine like a service 2026-11-17 13:48:57 +01:00
compose_oci_test.go Fix invalid path error when using OCI artifacts on Windows 2026-02-09 09:15:37 +01:00
compose_progress_test.go refactor(display): rebuild the TTY progress renderer on a model/layout/screen split 2026-09-09 16:50:05 +02:00
compose_test.go fix(compose): move the job-target refusal into projectOrName itself 2026-09-21 16:35:20 +02:00
config.go fix(config): skip pure resource provider services in config --images 2026-11-13 15:36:36 +01:00
config_test.go fix(config): skip pure resource provider services in config --images 2026-11-13 15:36:36 +01:00
cp.go golangci-lint: use gci formatter instead of goimports 2025-12-01 12:21:50 +01:00
create.go run: trigger a job through the engine like a service 2026-11-17 13:48:57 +01:00
create_test.go refactor(compose): share the --y flag normalization of create and up 2026-10-29 11:59:43 +01:00
down.go fix: COMPOSE_REMOVE_ORPHANS resolves identically for every command carrying the flag 2026-11-16 16:33:23 +01:00
events.go fix(events): validate service names before subscribing to events 2026-08-18 10:48:59 +02:00
exec.go golangci-lint: enable perfsprint linter 2026-09-10 10:25:34 +02:00
export.go build(lint): enable the dupl linter 2026-10-29 11:59:43 +01:00
generate.go golangci-lint: enable perfsprint linter 2026-09-10 10:25:34 +02:00
hooks.go feat: pre-filter Desktop Logs view by Compose project 2026-05-18 17:28:03 +02:00
hooks_test.go feat: pre-filter Desktop Logs view by Compose project 2026-05-18 17:28:03 +02:00
images.go go.mod: bump github.com/moby/moby/api v1.53.0, moby/client v0.2.2 2026-02-11 12:32:37 +01:00
kill.go fix: COMPOSE_REMOVE_ORPHANS resolves identically for every command carrying the flag 2026-11-16 16:33:23 +01:00
list.go chore: inline needless single-use helpers 2026-08-14 22:49:53 +02:00
logs.go docs: compose logs: add more links for flag descriptions 2026-06-10 09:36:31 +02:00
options.go cmd/prompt: remove uses of github.com/AlecAivazis/survey/v2 2026-09-11 15:30:07 +02:00
options_test.go build(deps): adopt compose-go jobs and the container-spec layering 2026-09-21 16:35:20 +02:00
orphans_env_test.go orphans: document the deliberate env-source asymmetry 2026-11-16 16:33:23 +01:00
pause.go build(lint): enable the dupl linter 2026-10-29 11:59:43 +01:00
port.go fix(port): preserve tie order for dual-stack port publishers 2026-09-14 10:48:03 +02:00
ps.go fix(ps): honor psFormat from Docker CLI config when no --format flag given 2026-08-20 14:05:34 +02:00
publish.go feat(compose): warn on unsupported compose-file attributes 2026-09-09 16:32:04 +02:00
pull.go run: trigger a job through the engine like a service 2026-11-17 13:48:57 +01:00
pullOptions_test.go build(deps): adopt compose-go jobs and the container-spec layering 2026-09-21 16:35:20 +02:00
push.go run: trigger a job through the engine like a service 2026-11-17 13:48:57 +01:00
push_test.go feat(push): deprecate --ignore-push-failures in favor of --ignore-missing 2026-10-16 18:08:20 +02:00
remove.go golangci-lint: use gci formatter instead of goimports 2025-12-01 12:21:50 +01:00
restart.go refactor: fix lint issues from cleanup changes 2026-05-12 11:31:40 +02:00
run.go run: trigger a job through the engine like a service 2026-11-17 13:48:57 +01:00
run_test.go run: trigger a job through the engine like a service 2026-11-17 13:48:57 +01:00
scale.go feat(compose): warn on unsupported compose-file attributes 2026-09-09 16:32:04 +02:00
start.go jobs: register scheduled jobs on create and up, remove them on down 2026-11-17 13:48:57 +01:00
stats.go feat(stats): add --all-projects and --aggregate flags 2026-10-15 06:41:29 +02:00
stats_projects.go refactor(compose): share the label filter builders 2026-10-29 11:59:43 +01:00
stats_projects_test.go fix(stats): bound the sampling and keep going when a container fails 2026-10-15 06:41:29 +02:00
stop.go refactor: fix lint issues from cleanup changes 2026-05-12 11:31:40 +02:00
top.go build(lint): enable the dupl linter 2026-10-29 11:59:43 +01:00
top_test.go fix mixed assertion libraries in tests 2026-03-31 17:32:51 +02:00
unsupported_attributes.go feat(compose): warn on unsupported compose-file attributes 2026-09-09 16:32:04 +02:00
unsupported_attributes_test.go feat(compose): warn on unsupported compose-file attributes 2026-09-09 16:32:04 +02:00
up.go jobs: register scheduled jobs on create and up, remove them on down 2026-11-17 13:48:57 +01:00
up_attach_test.go refactor(up): extract the selection of the attached services from runUp 2026-10-28 16:31:14 +01:00
up_test.go jobs: register scheduled jobs on create and up, remove them on down 2026-11-17 13:48:57 +01:00
version.go golangci-lint: use gci formatter instead of goimports 2025-12-01 12:21:50 +01:00
version_test.go golangci-lint: use gci formatter instead of goimports 2025-12-01 12:21:50 +01:00
viz.go feat(compose): warn on unsupported compose-file attributes 2026-09-09 16:32:04 +02:00
viz_test.go fix mixed assertion libraries in tests 2026-03-31 17:32:51 +02:00
volumes.go golangci-lint: use gci formatter instead of goimports 2025-12-01 12:21:50 +01:00
wait.go golangci-lint: use gci formatter instead of goimports 2025-12-01 12:21:50 +01:00
watch.go feat(compose): warn on unsupported compose-file attributes 2026-09-09 16:32:04 +02:00