[英]Docker run container on different port
I am new to docker. 我是码头工人的新手。 Just tried to run a container on port 80
刚尝试在端口80上运行容器
docker run -p 80:80 kitematic/hello-world-nginx
and it seems to be working fine. 它似乎工作正常。 I can get to the site at http://192.168.99.100/
我可以访问该网站http://192.168.99.100/
but i tried changing the port to 但我尝试将端口更改为
docker run -p 70:50 kitematic/hello-world-nginx
and i cannot get to site at http://192.168.99.100:70 . 我无法访问网站http://192.168.99.100:70 。 So how can i set a different port and connect to site please?
那么我该如何设置不同的端口并连接到网站呢?
Please try: 请试试:
docker run -p 70:80 kitematic/hello-world-nginx
binding port is probably mistyped in the command you provided. 绑定端口可能在您提供的命令中输入错误。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.