@@ -15,6 +15,9 @@ location ^~ /calibre-web/ {
1515 #error_page 401 =200 /ldaplogin;
1616
1717 # enable for Authelia, also enable authelia-server.conf in the default site config
18+ # To use Authelia to log in to Calibre-Web, make sure "Reverse Proxy Login" is
19+ # enabled, "Reverse Proxy Header Name" is set to Remote-User, and each Authelia
20+ # user also has a corresponding user manually created in Calibre-Web.
1821 #include /config/nginx/authelia-location.conf;
1922
2023 include /config/nginx/proxy.conf;
@@ -27,3 +30,18 @@ location ^~ /calibre-web/ {
2730 proxy_set_header X-Scheme $scheme;
2831 proxy_set_header X-Script-Name /calibre-web;
2932}
33+
34+ # OPDS feed for eBook reader apps
35+ # Even if you use Authelia, the OPDS feed requires a password to be set for
36+ # the user directly in Calibre-Web, as eBook reader apps don't support
37+ # form-based logins, only HTTP Basic auth.
38+ location ^~ /calibre-web/opds/ {
39+ include /config/nginx/proxy.conf;
40+ include /config/nginx/resolver.conf;
41+ set $upstream_app calibre-web;
42+ set $upstream_port 8083;
43+ set $upstream_proto http;
44+ proxy_pass $upstream_proto://$upstream_app:$upstream_port;
45+ proxy_set_header X-Scheme $scheme;
46+ proxy_set_header X-Script-Name /calibre-web;
47+ }
0 commit comments