To expose just one port, this is what you need to do:
docker run -p <host_port>:<container_port>
To expose multiple ports, simply provide multiple -p
arguments:
docker run -p <host_port1>:<container_port1> -p <host_port2>:<container_port2>
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…