blog icon indicating copy to clipboard operation
blog copied to clipboard

235. learn docker

Open ly525 opened this issue 6 years ago • 0 comments

yum install net-tools -y # for ifconfig

docker rm $(docker ps -a)

# docker run -p 127.0.0.1:80:8080 ubuntu bash
# docker run -p host:port:dockerPort image
# This binds port 8080 of the container to port 80 on 127.0.0.1 of the host machine. 
# The Docker User Guide explains in detail how to manipulate ports in Docker.
docker run -it -p 1337:1337 -v `pwd`:/srv/app strapi/strapi
docker run -it -p 1337:1337 -v `pwd`:/srv/app centos
docker run -it -p 1234:1337 -v `

ly525 avatar Jan 07 '19 06:01 ly525