2019-08-28 08:30:33 +02:00
|
|
|
#sub_path_only rewrite ^__PATH__$ __PATH__/ permanent;
|
2019-02-25 23:09:47 +01:00
|
|
|
# https://github.com/WeblateOrg/weblate/blob/master/examples/weblate.nginx.conf
|
2018-01-19 08:08:46 +01:00
|
|
|
location ^__PATH__/favicon.ico$ {
|
2017-09-14 09:33:06 +02:00
|
|
|
# DATA_DIR/static/favicon.ico
|
2017-09-15 10:58:04 +02:00
|
|
|
alias __FINALPATH__/data/static/favicon.ico;
|
2017-09-14 09:33:06 +02:00
|
|
|
expires 30d;
|
|
|
|
}
|
|
|
|
|
2018-01-19 08:08:46 +01:00
|
|
|
location ^__PATH__/robots.txt$ {
|
2017-09-14 09:33:06 +02:00
|
|
|
# DATA_DIR/static/robots.txt
|
2017-09-15 10:58:04 +02:00
|
|
|
alias __FINALPATH__/data/static/robots.txt;
|
2017-09-14 09:33:06 +02:00
|
|
|
expires 30d;
|
|
|
|
}
|
|
|
|
|
2018-01-19 08:08:46 +01:00
|
|
|
location __PATH__/static/ {
|
2017-09-14 09:33:06 +02:00
|
|
|
# DATA_DIR/static/
|
2017-09-15 10:58:04 +02:00
|
|
|
alias __FINALPATH__/data/static/;
|
2017-09-14 09:33:06 +02:00
|
|
|
expires 30d;
|
|
|
|
}
|
|
|
|
|
2018-01-19 08:08:46 +01:00
|
|
|
location __PATH__/media/ {
|
2017-09-14 09:33:06 +02:00
|
|
|
# DATA_DIR/media/
|
2017-09-15 10:58:04 +02:00
|
|
|
alias __FINALPATH__/data/media/;
|
2017-09-14 09:33:06 +02:00
|
|
|
expires 30d;
|
|
|
|
}
|
2019-02-25 23:09:47 +01:00
|
|
|
|
2019-08-28 08:30:33 +02:00
|
|
|
location __PATH__/ {
|
2019-02-25 23:09:47 +01:00
|
|
|
# Path to source
|
|
|
|
alias __FINALPATH__/ ;
|
|
|
|
|
|
|
|
include uwsgi_params;
|
|
|
|
# Needed for long running operations in admin interface
|
|
|
|
uwsgi_read_timeout 3600;
|
|
|
|
uwsgi_pass unix:///var/run/__NAME__/socket;
|
|
|
|
|
|
|
|
# Include SSOWAT user panel.
|
|
|
|
include conf.d/yunohost_panel.conf.inc;
|
2019-08-28 08:30:33 +02:00
|
|
|
}
|