Giter Site home page Giter Site logo

Comments (4)

gotson avatar gotson commented on May 30, 2024 1

You are probably missing forward headers like X-Forwarded-Proto

Check the closed issues, there's numerous people who can't configure nginx properly for reverse proxy. Or better, use Caddy, which works outside the box.

from komga.

PatrickTCB avatar PatrickTCB commented on May 30, 2024

Have you maybe set this via an environment variable? Can you post the relevant environment variables?

These urls are set in komga-webui/src/functions/urls.ts. Unless the dev environment variables have been set they should be https whenever loaded from https.

const fullUrl = process.env.VUE_APP_KOMGA_API_URL
  ? process.env.VUE_APP_KOMGA_API_URL
  : window.location.origin + window.resourceBaseUrl
const baseUrl = process.env.NODE_ENV === 'production' ? window.resourceBaseUrl : '/'

const urls = {
  origin: !fullUrl.endsWith('/') ? `${fullUrl}/` : fullUrl,
  originNoSlash: fullUrl.endsWith('/') ? fullUrl.slice(0, -1) : fullUrl,
  base: !baseUrl.endsWith('/') ? `${baseUrl}/` : baseUrl,
  baseNoSlash: baseUrl.endsWith('/') ? baseUrl.slice(0, -1) : baseUrl,
} as Urls

from komga.

yatounoneko avatar yatounoneko commented on May 30, 2024

Oh, you are right! I hadn’t searched for nginx in the closed issues because I thought the problem was not about Nginx.

It turns out you were right; I found that issue #1322 has a solution for this problem.
I tried adding the config proxy_set_header X-Forwarded-Proto $scheme; to my nginx reverse proxy.

Now my epub book has been restored. Thanks for your help!

from komga.

FlashDoggy avatar FlashDoggy commented on May 30, 2024

You are probably missing forward headers like X-Forwarded-Proto

Check the closed issues, there's numerous people who can't configure nginx properly for reverse proxy. Or better, use Caddy, which works outside the box.

Hi, I also faced this problem but i'm using apache as reverseproxy, and according to the X-Forwarded-Proto. I added this sentence
RequestHeader setifempty X-Forwarded-Proto "https"
and it works.

Hope this could work for you, I think it's the problem of the https head misuse.

from komga.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.