The first contact Docker deployment encountered many problems, such as the famous IP port mapping problem.
The reality is that you need to package the Web app as a mirror, and pass the configuration parameters (database, IP, port, etc.) through the shell script to the mirror, to achieve a build, running everywhere. However, the IP mapping problem was encountered during the parameter transfer. The Docker container is probably similar to the "virtual machine" mechanism, which contains a separate system and therefore has its own IP and port, and the IP and port of the IP and the primary system (server) need to be connected to generate communication (presumably). Then the IP passed to the container can not be the IP of the desired host, for example, we try to set the IP of the mirror service to 192.168.6.29, because this is the IP of the host, the result is to start the error, prompt as shown above. Check for a long time, just a blog is right, is the mapping problem. Of course, there may be a Hosts file error, try to troubleshoot. In fact, here only need to set IP as: 0.0.0.0, the IP is representative of all the local IP, good for example 127.0.0.1 represents the local IP.
And then stick to the Docker command you've just learned, and maybe use it:
View the Docker:docker ps|grep xxxx in operation
See all Docker:docker ps-a|grep xxxx
Stop Docker run: Docker stop container ID
Run the Docker:docker run container ID
entering container: Docker exec-it container ID bash (you need to see the ID of the container first using Docker PS)
Exit Container: exit
manual start Mirror: Docker run-d-P Port: Port mirroring Address startup file. SH
manually view the Docker log (if the container fails to start): Docker logs-f container ID