I have one django-admin application with a name myappthat I would like to deploy multiple instances in different physical boxes, one for each client. Nevertheless, I would like to see all of them are available from the same domain mydomain.com/customer1/myapp.
I searched for specific proxy settings and tried a few things suggested on SO, but none of them are suitable for my use ... and since I know very little about nginxand django, I am at a loss!
My current nginx.conf:
server {
listen 80;
server_name myserver.com
location ^~ /static {
alias /path/to/static/files/;
}
location ^~ /customer1/myapp/static {
alias /path/to/static/files/;
}
location /customer1/myapp {
rewrite ^/customer1/myapp/(/?)(.*) /$2 break;
proxy_pass http://127.0.0.1:8001;
}
}
, , myserver.com/customer1/myapp/admin. , , nginx url myserver.com/admin, URL-. nginx URL- URL-, 127.0.0.1:8001?
FWIW, gunicorn gunicorn -b 127.0.0.1:8001 -n myapp. / , .
, . , django nginx.conf .