koreader-sync-server icon indicating copy to clipboard operation
koreader-sync-server copied to clipboard

Option to use HTTP

Open xenoryt opened this issue 4 years ago • 4 comments
trafficstars

Correct me if I'm wrong, but from what I can tell it seems the koreader/kosync docker image automatically tries to use https and provides its own certificates?

While this does make it easy to setup, I would like to have an option to disable https and have the server work with just regular http. I have traefik running as a reverse proxy in front of the server which handles https and routes traffic to the appropriate backend.

xenoryt avatar Jan 25 '21 04:01 xenoryt

Hi

Did you find a solution to this? I would like to proxy it as well.

gerroon avatar Jul 02 '21 16:07 gerroon

I don't really use koreader anymore so I haven't looked deeply into this. But to get around this issue, will probably have to create your own docker image without the nginx setup in the provided image.

xenoryt avatar Jul 04 '21 00:07 xenoryt

It looks like there is also an HTTP config block:

https://github.com/koreader/koreader-sync-server/blob/master/config/nginx.conf#L26

Its port is 1 concatenated with the HTTPS port number (7200 unless you set GIN_PORT to something else), thus 17200 by default.

sabberworm avatar Oct 05 '21 20:10 sabberworm

docker run -d --restart=always -p 17200:17200 -p 7200:7200 \\n    -v `pwd`/logs/app:/app/koreader-sync-server/logs \\n    -v `pwd`/logs/redis:/var/log/redis \\n    -v `pwd`/data/redis:/var/lib/redis \\n    --name=koreader_sync koreader/kosync:latest

nginx ssl proxy to 17200 is ok,tks @sabberworm

davidwang558 avatar Jun 06 '22 08:06 davidwang558