I am trying to put a development server in place on the same server as the production server. The two will run on different ports, and one will be accessible via prod.example.com
and the other via dev.example.com
. There is a DNS A
record in place already.
I would like the following :
www.example.com => port 9393 www1.example.com => port 9393 anysubdomain.example.com => port 9393 dev.example.com => port 19393
Here is what I have so far (not working) :
http { server { listen 80; server_name localhost; root /var/www/...; Location / { proxy_pass http://127.0.0.1:9393/; } server { listen 80; server_name dev.*; location / { proxy_pass http://localhost:19393; } } }
I've seen the following Q/A :
default
help ?