hello guys, totally stuck, hoping to get some help here.
I have Nginx and PHP - two containers. Nginx i want to run in network_mode = host to get real ip addresses in access log files. PHP container - i want to remain not exposed to host. But no for some reason i can’t get it to work . Trivial situation, i believe any of you have done this before?
Here’s my file
# docker-compose.yml version: "3.8" services: nginx: build: ./docker/nginx container_name: nginx command: nginx -g "daemon off;" network_mode: host php: container_name: php build: ./docker/php ports: - "9000:9000" networks: - mynet command: bash -c "service cron start && php-fpm" #tail -f /dev/null networks: mynet:
I create a network mynet, specify that php uses that net, and from nginx config i access
as a result i get some error about uplink or stuff, what do i miss or what do i do wrongly?