Last active
February 27, 2019 07:30
-
-
Save riddla/dcb657b263943a85264e57dc14e45279 to your computer and use it in GitHub Desktop.
Switch between localhost and container node application in "dockered" NGINX
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
upstream node-app { | |
# Enable this to use theserver running inside docker | |
# server node-app:3000; | |
# Enable this to use the (development) server running on your localhost | |
server host.docker.internal:3000; | |
} | |
server { | |
location / { | |
proxy_pass http://node-app; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment