podman-compose - Man Page
Run Compose workloads via an external compose provider
Examples (TL;DR)
- List all running containers:
podman-compose ps
- Create and start all containers in the background using a local
docker-compose.yml
:podman-compose up -d
- Start all containers, building if needed:
podman-compose up --build
- Start all containers using an alternate compose file:
podman-compose -f|--file path/to/file.yaml up
- Stop all running containers:
podman-compose stop
- Remove all containers, networks, and volumes:
podman-compose down --volumes
- Follow logs for a container (omit all container names):
podman-compose logs --follow container_name
- Run a one-time command in a service with no ports mapped:
podman-compose run service_name command
Synopsis
podman compose [options] [command [arg ...]]
Description
podman compose is a thin wrapper around an external compose provider such as docker-compose or podman-compose. This means that podman compose is executing another tool that implements the compose functionality but sets up the environment in a way to let the compose provider communicate transparently with the local Podman socket. The specified options as well the command and argument are passed directly to the compose provider.
The default compose providers are docker-compose and podman-compose. If installed, docker-compose takes precedence since it is the original implementation of the Compose specification and is widely used on the supported platforms (i.e., Linux, Mac OS, Windows).
If you want to change the default behavior or have a custom installation path for your provider of choice, please change the compose_provider field in containers.conf(5). You may also set the PODMAN_COMPOSE_PROVIDER environment variable.
By default, podman compose will emit a warning saying that it executes an external command. This warning can be disabled by setting compose_warning_logs to false in containers.conf(5) or setting the PODMAN_COMPOSE_WARNING_LOGS environment variable to false. See the man page for containers.conf(5) for more information.
Options
To see supported options of the installed compose provider, please run podman compose --help.
See Also
Referenced By
The man page docker-compose(1) is an alias of podman-compose(1).