Skip to content

Commit d47f0f3

Browse files
laurazardndeloof
authored andcommitted
Update docs to mention COMPOSE_PARALLEL_LIMITS and ways to configure parallelism
Signed-off-by: Laura Brehm <[email protected]>
1 parent ac8ab86 commit d47f0f3

File tree

2 files changed

+20
-2
lines changed

2 files changed

+20
-2
lines changed

docs/reference/compose.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,13 +141,22 @@ You can also enable multiple profiles, e.g. with `docker compose --profile front
141141

142142
Profiles can also be set by `COMPOSE_PROFILES` environment variable.
143143

144+
### Configuring parallelism
145+
146+
Use `--parallel` to specify the maximum level of parallelism for concurrent engine calls.
147+
Calling `docker compose --parallel 1 pull` will pull the pullable images defined in the Compose file
148+
one at a time. This can also be used to control build concurrency.
149+
150+
Parallelism can also be set by the `COMPOSE_PARALLEL_LIMIT` environment variable.
151+
144152
### Set up environment variables
145153

146154
You can set environment variables for various docker compose options, including the `-f`, `-p` and `--profiles` flags.
147155

148156
Setting the `COMPOSE_FILE` environment variable is equivalent to passing the `-f` flag,
149157
`COMPOSE_PROJECT_NAME` environment variable does the same as the `-p` flag,
150-
and `COMPOSE_PROFILES` environment variable is equivalent to the `--profiles` flag.
158+
`COMPOSE_PROFILES` environment variable is equivalent to the `--profiles` flag
159+
and `COMPOSE_PARALLEL_LIMIT` does the same as the `--parallel` flag.
151160

152161
If flags are explicitly set on the command line, the associated environment variable is ignored.
153162

docs/reference/docker_compose.yaml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,13 +89,22 @@ long: |-
8989
9090
Profiles can also be set by `COMPOSE_PROFILES` environment variable.
9191
92+
### Configuring parallelism
93+
94+
Use `--parallel` to specify the maximum level of parallelism for concurrent engine calls.
95+
Calling `docker compose --parallel 1 pull` will pull the pullable images defined in the Compose file
96+
one at a time. This can also be used to control build concurrency.
97+
98+
Parallelism can also be set by the `COMPOSE_PARALLEL_LIMIT` environment variable.
99+
92100
### Set up environment variables
93101
94102
You can set environment variables for various docker compose options, including the `-f`, `-p` and `--profiles` flags.
95103
96104
Setting the `COMPOSE_FILE` environment variable is equivalent to passing the `-f` flag,
97105
`COMPOSE_PROJECT_NAME` environment variable does the same as the `-p` flag,
98-
and `COMPOSE_PROFILES` environment variable is equivalent to the `--profiles` flag.
106+
`COMPOSE_PROFILES` environment variable is equivalent to the `--profiles` flag
107+
and `COMPOSE_PARALLEL_LIMIT` does the same as the `--parallel` flag.
99108
100109
If flags are explicitly set on the command line, the associated environment variable is ignored.
101110

0 commit comments

Comments
 (0)