linuxserver / docker-calibre-web

GNU General Public License v3.0
1.01k stars 144 forks source link

[BUG] Traefik v3 breaks calibre-web UI #294

Closed zaggash closed 4 months ago

zaggash commented 4 months ago

Is there an existing issue for this?

Current Behavior

All JS Jquery are not working.

The most obvious issues are the dropdown menu which are not working. Or the "+" menu in the admin area are not opening.

If anyone has an idea !

Expected Behavior

The dropdown menu should open a show options The "+" menus in the admin area should expand

Steps To Reproduce

Add traefik v3 in front of calibre web.

Environment

- OS: Unraid
- How docker service was installed: docker compose with traefik as reverse.

CPU architecture

x86-64

Docker creation

https://github.com/zaggash/homelab/blob/main/unraid-homelab/media/calibre-web-compose.yaml

Container logs

No log in the container.
github-actions[bot] commented 4 months ago

Thanks for opening your first issue here! Be sure to follow the relevant issue templates, or risk having this issue marked as invalid.

j0nnymoe commented 4 months ago

Hey @zaggash long time no speak 😊. You need to report this to calibre web or it's a problem with your traefik config, if it's working fine without traefik, it's not something we need to change in the container.

zaggash commented 4 months ago

Hello :) Yup I agree, opened here in case it happens to someone. I'll cross post upstream.

zaggash commented 4 months ago

My bad after further testing, it seems to be something in my config. I'll dig further and report here the wrong setup

zaggash commented 4 months ago

For some reason the compression is causing issues in this version:

middlewares:
    compress-all:
      compress:
        excludedContentTypes:
          - text/event-stream

Closing !

zaggash commented 4 months ago

For tracking purpose Maybe https://github.com/traefik/traefik/issues/9734 ?

danepowell commented 3 months ago

I don't think https://github.com/traefik/traefik/issues/9734 is the whole story, since I'm on v3.0.2 (supposedly fixed) and still seeing the issue.

I first noticed the menu dropdown not working on mobile after upgrading to Traefik v3 and traced it back to all the JS files served by calibre-web being just 1 byte (a semicolon).

https://github.com/linuxserver/docker-calibre-web/issues/294#issuecomment-2099452871 didn't fix it for me. I had to disable the compress middleware altogether.

zaggash commented 3 months ago

Yup. Mee too. I pasted the config here. But I had to disable the compress middleware completely.

danepowell commented 2 months ago

Yeah, I had to apply a custom middleware to the calibre service to disable compression. Definitely still a bug in traefik and/or calibre though.