36 lines
No EOL
725 B
Text
36 lines
No EOL
725 B
Text
# the upstream component nginx needs to connect to
|
|
upstream django {
|
|
server unix://{hd}/run/saleor.sock;
|
|
}
|
|
|
|
# configuration of the server
|
|
server {
|
|
listen 80;
|
|
server_name {host} www.{host};
|
|
charset utf-8;
|
|
|
|
# max upload size
|
|
client_max_body_size 75M;
|
|
|
|
# Django media and static files
|
|
location {media} {
|
|
alias /var/www/{host}{media};
|
|
}
|
|
|
|
location {static} {
|
|
alias /var/www/{host}{static};
|
|
}
|
|
|
|
# Send all non-media requests to the Django server.
|
|
location / {
|
|
uwsgi_pass django;
|
|
include {hd}/saleor/uwsgi_params;
|
|
}
|
|
|
|
location /graphql/ {
|
|
proxy_pass https://{api_host}:{api_port};
|
|
}
|
|
|
|
{dashboard-location}
|
|
|
|
} |