1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/coin_ynh.git synced 2024-09-03 18:16:26 +02:00
coin_ynh/conf/nginx.conf

31 lines
842 B
Nginx Configuration File
Raw Normal View History

2017-04-09 11:05:39 +02:00
location PATHTOCHANGE {
if ($scheme = http) {
rewrite ^ https://$server_name$request_uri? permanent;
}
try_files $uri @YNH_APP_INSTANCE_NAME;
}
location /protected/ {
internal;
alias /opt/YNH_APP_INSTANCE_NAME/YNH_APP_INSTANCE_NAME/smedia/;
}
2018-11-11 01:58:40 +01:00
location PATHTOCHANGEmedia {
2017-04-09 11:05:39 +02:00
alias /opt/YNH_APP_INSTANCE_NAME/media;
}
2018-11-11 01:58:40 +01:00
location PATHTOCHANGEstatic {
2017-04-09 11:05:39 +02:00
alias /opt/YNH_APP_INSTANCE_NAME/static;
}
2018-11-11 01:58:40 +01:00
location PATHTOCHANGEassets {
2017-04-09 11:05:39 +02:00
alias /opt/YNH_APP_INSTANCE_NAME/static;
}
location @YNH_APP_INSTANCE_NAME {
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_pass http://unix:/opt/YNH_APP_INSTANCE_NAME/sock;
}