Also, the MySQL is running on your localhost and the host machine does not expose any port to the outside world. Now, you want to access the MySQL server in your host machine from the Nginx container. And you have a MySQL database running in your host machine. Suppose you have an Nginx web server running inside an Nginx container in your host machine.