[GH-ISSUE #147] How to reverse proxy with nginx to shiori? #106

Closed
opened 2026-02-25 23:33:27 +03:00 by kerem · 1 comment
Owner

Originally created by @ghost on GitHub (Aug 30, 2019).
Original GitHub issue: https://github.com/go-shiori/shiori/issues/147

I have the following configuration in nginx.

server {
        listen 443 ssl http2;
        listen [::]:443 ssl http2;

        server_name example.com

        # SSL
        ssl_certificate /etc/letsencrypt/live/example.com/fullchain.pem;
        ssl_certificate_key /etc/letsencrypt/live/example.com/privkey.pem;
        ssl_trusted_certificate /etc/letsencrypt/live/example.com/chain.pem;

        # security
        #include nginxconfig.io/security.conf;

        # index.php
        index index.php;

        location / {
                proxy_pass http://127.0.0.1:8080;
                proxy_set_header    Host            $host;
                proxy_set_header    X-Real-IP       $remote_addr;
                proxy_set_header    X-Forwarded-for $remote_addr;
                port_in_redirect off;
                proxy_connect_timeout 300;
        }

        include nginxconfig.io/general.conf;
}

When I go to the site it shows a error and no css or images are loaded.

2019-08-30-132915_272x322_scrot

Originally created by @ghost on GitHub (Aug 30, 2019). Original GitHub issue: https://github.com/go-shiori/shiori/issues/147 I have the following configuration in nginx. ``` server { listen 443 ssl http2; listen [::]:443 ssl http2; server_name example.com # SSL ssl_certificate /etc/letsencrypt/live/example.com/fullchain.pem; ssl_certificate_key /etc/letsencrypt/live/example.com/privkey.pem; ssl_trusted_certificate /etc/letsencrypt/live/example.com/chain.pem; # security #include nginxconfig.io/security.conf; # index.php index index.php; location / { proxy_pass http://127.0.0.1:8080; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-for $remote_addr; port_in_redirect off; proxy_connect_timeout 300; } include nginxconfig.io/general.conf; } ``` When I go to the site it shows a error and no css or images are loaded. ![2019-08-30-132915_272x322_scrot](https://user-images.githubusercontent.com/980/64040081-2ddc7b80-cb2a-11e9-9a7e-cf007ddee2b2.png)
kerem closed this issue 2026-02-25 23:33:27 +03:00
Author
Owner

@ghost commented on GitHub (Aug 30, 2019):

My fault, It had to do with a setting in my general.conf where I was caching some stuff.

<!-- gh-comment-id:526685512 --> @ghost commented on GitHub (Aug 30, 2019): My fault, It had to do with a setting in my general.conf where I was caching some stuff.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/shiori#106
No description provided.