Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Software > Calibre > Server

Notices

Reply
 
Thread Tools Search this Thread
Old 01-18-2020, 11:30 PM   #1
vinuabe4
Junior Member
vinuabe4 began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Jan 2020
Device: none
Calibre http to https nginx reverse proxy issue

I have installed calibre web server on ubuntu server and I used nginx reverse proxy to enable SSL. Please find my below mentioned calibre nginx config.
Code:
server {
listen 80;
server_name ebooks.everly.to;


location / {
               proxy_buffering off;
               proxy_pass http://78.46.187.23:8080$request_uri;
return         301 https://$server_name$request_uri;
        }
}

server {
listen 443;
server_name ebooks.everly.to;
ssl on;
        ssl_certificate /opt/certificate.crt;
        ssl_certificate_key /opt/private.key;
        ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
        ssl_ciphers HIGH:!aNULL:!MD5;
        access_log /var/log/calibre-server-access.log;
        error_log /var/log/calibre-server-error.log info;
        proxy_set_header X-Forwarded-For $remote_addr;


location /calibre/web/ {

proxy_set_header        Host                $http_host;
    # The line below is the key line you need:
    proxy_set_header        X-Scheme            $scheme;
    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_intercept_errors  on;
    proxy_http_version      1.1;


    proxy_pass              http://78.46.187.23:8080;
}
}
but when I using "return 301 https://$server_name$request_uri;" to forward http traffic to https I am getting "Failed to communicate with "/interface-data/init?1579406936518", network error. Is the server running and accessible?" error

please help me with this

Last edited by PeterT; 01-18-2020 at 11:42 PM.
vinuabe4 is offline   Reply With Quote
Old 01-20-2020, 02:03 AM   #2
vinuabe4
Junior Member
vinuabe4 began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Jan 2020
Device: none
bump..
vinuabe4 is offline   Reply With Quote
Advert
Old 01-20-2020, 08:01 AM   #3
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 43,744
Karma: 22446736
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
WHy is your proxy section so complex? Just use the basic one described here: https://manual.calibre-ebook.com/server.html

And look at the logs of both nginx and the calibre server to see what the issue might be.
kovidgoyal is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help: Using NGINX as reverse-proxy for Calibre haertig Related Tools 5 11-18-2017 08:54 PM
Calibre-server reverse proxy issues dom134 Related Tools 12 05-30-2016 04:39 PM
Nginx Calibre Proxy Ackis Calibre 2 04-19-2016 01:48 PM
Aldiko + Calibre-Server + Reverse Proxy dummkauf Related Tools 4 02-02-2016 02:55 PM
Content server apache reverse proxy issue bossanova808 Calibre 13 09-16-2011 09:38 AM


All times are GMT -4. The time now is 02:18 AM.


MobileRead.com is a privately owned, operated and funded community.