2017-08-20 03:56:32 +00:00
|
|
|
server {
|
|
|
|
server_name news.example.com;
|
|
|
|
listen 80; # adding HTTPS configuration is highly recommended
|
|
|
|
# redirect to HTTPS, if desired
|
|
|
|
#if ($https != "on") {rewrite ^ https://$host$request_uri;}
|
|
|
|
# the userPreAuth setting should be enabled if the Web server is handling authentication
|
|
|
|
#auth_basic "Advanced RSS Environment";
|
|
|
|
root /usr/share/arsse/www;
|
|
|
|
index index.html;
|
2018-10-26 18:58:04 +00:00
|
|
|
|
2017-08-20 03:56:32 +00:00
|
|
|
location / {
|
|
|
|
try_files $uri $uri/ =404;
|
|
|
|
}
|
2017-08-29 00:20:49 +00:00
|
|
|
|
|
|
|
location @arsse_auth {
|
|
|
|
# the userPreAuth setting should be enabled if the Web server is handling authentication
|
|
|
|
#auth_basic "Advanced RSS Environment";
|
|
|
|
include /usr/share/arsse/dist/nginx-fcgi.conf;
|
|
|
|
}
|
|
|
|
|
|
|
|
location @arsse_no_auth {
|
|
|
|
auth_basic off;
|
|
|
|
include /usr/share/arsse/dist/nginx-fcgi.conf;
|
|
|
|
}
|
2018-10-26 18:58:04 +00:00
|
|
|
|
2017-10-30 18:50:31 +00:00
|
|
|
# NextCloud News protocol
|
2017-08-20 03:56:32 +00:00
|
|
|
location /index.php/apps/news/api {
|
2017-08-29 00:20:49 +00:00
|
|
|
try_files $uri @arsse_auth;
|
2018-10-26 18:58:04 +00:00
|
|
|
|
2017-08-20 03:56:32 +00:00
|
|
|
location ~ ^/index\.php/apps/news/api/?$ {
|
2017-08-29 00:20:49 +00:00
|
|
|
try_files $uri @arsse_no_auth;
|
2017-08-20 03:56:32 +00:00
|
|
|
}
|
|
|
|
}
|
2017-10-30 18:50:31 +00:00
|
|
|
|
|
|
|
# Tiny Tiny RSS protocol
|
|
|
|
location /tt-rss/api {
|
|
|
|
try_files $uri @arsse_no_auth;
|
|
|
|
}
|
|
|
|
|
|
|
|
# Tiny Tiny RSS feed icons
|
|
|
|
location /tt-rss/feed-icons/ {
|
|
|
|
try_files $uri @arsse_no_auth;
|
|
|
|
}
|
|
|
|
|
|
|
|
# Tiny Tiny RSS special-feed icons
|
|
|
|
location /tt-rss/images/ {
|
2017-11-30 04:41:08 +00:00
|
|
|
auth_basic off;
|
2017-10-30 18:50:31 +00:00
|
|
|
root /usr/share/arsse/www;
|
2017-11-27 18:05:08 +00:00
|
|
|
try_files $uri =404;
|
2017-10-30 18:50:31 +00:00
|
|
|
}
|
2018-10-26 18:58:04 +00:00
|
|
|
}
|