docker compose pull (original) (raw)
Description | Pull service images |
---|---|
Usage | docker compose pull [OPTIONS] [SERVICE...] |
Pulls an image associated with a service defined in a compose.yaml
file, but does not start containers based on those images
Option | Default | Description |
---|---|---|
--ignore-buildable | Ignore images that can be built | |
--ignore-pull-failures | Pull what it can and ignores images with pull failures | |
--include-deps | Also pull services declared as dependencies | |
--policy | Apply pull policy ("missing"|"always") | |
-q, --quiet | Pull without printing progress information |
Consider the following compose.yaml
:
If you run docker compose pull ServiceName
in the same directory as the compose.yaml
file that defines the service, Docker pulls the associated image. For example, to call the postgres image configured as the db service in our example, you would run docker compose pull db
.
docker compose pull
tries to pull image for services with a build section. If pull fails, it lets you know this service image must be built. You can skip this by setting --ignore-buildable
flag.