kiwix / kiwix-tools

Command line Kiwix tools: kiwix-serve, kiwix-manage, ...
https://download.kiwix.org/release/kiwix-tools/
GNU General Public License v3.0
407 stars 79 forks source link

Simple HTTPS workaround #684

Open CasaPas opened 1 week ago

CasaPas commented 1 week ago

I just installed Kiwix in a docker container on my Unraid server.

Some of the Zim files won't open due to the known "HTTPS service worker" issue.

The problem being, that generally you access Kiwix via your remote browser pointing to the IP address of the Unraid server, rather than "localhost" if the files were on the host machine.

I managed to get these Zim files working, by installing a Firefox docker on the Unraid server, and setting its networking to "host" rather than "bridge". Basically this browser has access to the "host" or local files. Using this docker container browser, you are now able to access "localhost:8040" version of Kiwix.

I can now connect to my Kiwix server from a remote machine, looking at the Unraid Firefox browser using localhost:8040/ as an address inside the Firefox docker rather than using the IP address of the Unraid server in the remote or Unraid browser.

It's a bit cumbersome, but it works until the release of the new version which is due to solve this issue.

So;

1: Local browser -> 2: Unraid Browser (IPofUnraidServer:3000) -> 3: localhost:8040

1: Tab in my remote machine pointing to the Unraid docker gui for Firefox (X.X.X.X:3000) 2: Tab inside the Firefox docker pointing to the "local" web gui for Kiwix (localhost:8040) 3: Kiwix running "locally" on the host Unraid system.

Clear as mud, as we say in Ireland.

Hope that helps someone.