klutchell / mediaserver

docker-based plex & usenet media server using custom subdomains with tls

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

nzbget-api rule regex results in traefik error

jokull opened this issue · comments

See error below.

traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="Configuration loaded from flags."
traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="Traefik version 2.2.0 built on 2020-03-25T17:32:57Z"
traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="\nStats collection is disabled.\nHelp us improve Traefik by turning this feature on :)\nMore details on: https://docs.traefik.io/contributing/data-collection/\n"
traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="Starting provider aggregator.ProviderAggregator {}"
traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="Starting provider *acme.Provider {\"email\":\"jokull@solberg.is\",\"caServer\":\"https://acme-v02.api.letsencrypt.org/directory\",\"storage\":\"/etc/traefik/acme.json\",\"keyType\":\"RSA4096\",\"tlsChallenge\":{},\"ResolverName\":\"tlschallenge\",\"store\":{},\"ChallengeStore\":{}}"
traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="Testing certificate renew..." providerName=tlschallenge.acme
traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="Starting provider *docker.Provider {\"watch\":true,\"endpoint\":\"unix:///var/run/docker.sock\",\"defaultRule\":\"Host(`{{ normalize .Name }}`)\",\"swarmModeRefreshSeconds\":15000000000}"
traefik_1  | time="2020-04-28T13:43:50Z" level=info msg="Starting provider *traefik.Provider {}"
traefik_1  | time="2020-04-28T13:43:51Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" entryPointName=https routerName=nzbget-api@docker
traefik_1  | time="2020-04-28T13:43:53Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" routerName=nzbget-api@docker entryPointName=https
traefik_1  | time="2020-04-28T13:44:03Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" entryPointName=https routerName=nzbget-api@docker
traefik_1  | time="2020-04-28T13:44:20Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" routerName=nzbget-api@docker entryPointName=https
traefik_1  | time="2020-04-28T13:44:24Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" entryPointName=https routerName=nzbget-api@docker
traefik_1  | time="2020-04-28T13:44:26Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" entryPointName=https routerName=nzbget-api@docker
traefik_1  | time="2020-04-28T13:44:29Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" entryPointName=https routerName=nzbget-api@docker
traefik_1  | time="2020-04-28T13:44:30Z" level=error msg="mux: path must start with a slash, got \"(/[^\\\\/:]*:[^\\\\/:]*)?/jsonrpc\"" entryPointName=https routerName=nzbget-api@docker

can you try with the fix I just pushed?

Works. Thank you!

New to docker-compose ... wondering how to persist htpasswd and configs between down/up and hardware restarts. If this is too junior a question I will probably figure it out on my own :)

If you follow the steps for htpasswd on the README, then it will persist. I use this service heavily so I would be concerned if any of my configuration did not persist :)

docker-compose exec traefik apk add --no-cache apache2-utils
docker-compose exec traefik htpasswd -c /etc/traefik/.htpasswd <user1>
docker-compose exec traefik htpasswd /etc/traefik/.htpasswd <user2>

This works because /etc/traffic is a mapped volume in docker-compose.yml.

https://github.com/klutchell/mediaserver/blob/master/docker-compose.yml#L158

The volumes defined at the top of the compose file will never disappear on their own. Even with docker-compose down and hardware restarts. Docker volumes require manual deletion and it is difficult to do it accidentally.

Okay I hadn’t caught that. This is brilliant. Very clean setup. Coming from plexguide, which is also nice but I’m moving from Ubuntu to a Mac Mini now.

Thanks for the feedback! Clean is what I was going for, knowing that there are many complex solutions available already.

For whatever reason http basic auth is working on all routes except nzbget. Could it be related to the recent fix? It does bring up the user/pass challenge in the browser but the combo does not work.

I forgot that NZBGet ships with basic auth enabled by default, so you will get double prompted unless you turn that off.

  1. first prompt should be your basic auth (htpasswd) credentials
  2. second prompt will require nzbget:tegbzn6789 until you go into NZBGet settings->security and remove the control username

I'll add something to the readme.

Gotcha! I did this:

docker exec -ti mediaserver_nzbget_1 /bin/bash
# edit /config/nzbget.conf to remove httpbasicauth
ps  # to grab the process id
kill -SIGHUP 235

This reloaded the config and now basic auth works.

BTW does traefik create an open network layer between the dockers? Wondering if Sonarr and nzb address each other. Is that on localhost or do I just use DNS and route publicly with auth credentials?

Yes, they are all on the same bridge network.

For example, Sonarr can reach NZBGet directly via nzbget:6789.

Everything is working now. Million dollar setup with traefik and letsencrypt.

Cheers friend!