docker-compose-port(1)

docker-compose-port1

Print the public port for a port binding

Usage

docker compose port [OPTIONS] SERVICE PRIVATE_PORT

Overview

Prints the public port for a port binding

Options

-h, --help[=false]
help for port

--index=0
Index of the container if service has multiple replicas

--protocol="tcp"
tcp or udp

Options inherited from parent commands

--dry-run[=false]
Execute command in dry run mode

From docker-compose 2.26.1-4 in Debian 13 (Trixie). Parsed by carta from the page's man source.