jittering / traefik-kop

A dynamic docker->redis->traefik discovery agent
MIT License
179 stars 13 forks source link

Error invalid syntax providerName=docker #10

Closed strausmann closed 1 year ago

strausmann commented 2 years ago

Hello,

I have a problem. I have Traefik running in my HomeLab on a Docker Swarm cluster. Traefik of course uses the Docker provider for this.

For this I then did the configuration as described for traefik-kop. Redis with on the Docker cluster.

The container mut the docker-kop runs on my Synology NAS. Now when I start another container with NGINX and traefik label on the Synology NAS, I get the following error message.

Any idea what can be wrong? You can't really do much wrong with the syntax.

time="2022-04-30T22:52:32Z" level=info msg="Starting provider aggregator.ProviderAggregator {}"
time="2022-04-30T22:52:32Z" level=info msg="Starting provider *docker.Provider {\"watch\":true,\"endpoint\":\"unix:///var/run/docker.sock\",\"swarmModeRefreshSeconds\":\"15s\"}"
time="2022-04-30T22:52:32Z" level=error msg="Skip container nginx-traefik-central: strconv.ParseBool: parsing \"true\\\"\": invalid syntax" providerName=docker
time="2022-04-30T22:52:32Z" level=info msg="refreshing configuration"
time="2022-04-30T22:54:54Z" level=info msg="Skipping same configuration" providerName=docker
time="2022-04-30T22:56:55Z" level=error msg="Skip container nginx01-traefik-central: strconv.ParseBool: parsing \"true\\\"\": invalid syntax" providerName=docker
time="2022-04-30T22:56:55Z" level=info msg="Skipping same configuration" providerName=docker
time="2022-04-30T23:03:15Z" level=error msg="Skip container nginx01-traefik-central: strconv.ParseBool: parsing \"true\\\"\": invalid syntax" providerName=docker
time="2022-04-30T23:03:19Z" level=info msg="Skipping same configuration" providerName=docker
time="2022-04-30T23:04:31Z" level=info msg="Skipping same configuration" providerName=docker
time="2022-04-30T23:05:18Z" level=error msg="Skip container nginx01-test: strconv.ParseBool: parsing \"true\\\"\": invalid syntax" providerName=docker
time="2022-04-30T23:05:18Z" level=info msg="Skipping same configuration" providerName=docker

Thank you

best regards

strausmann commented 2 years ago

Which data cannot be parsed here? Then I would on the Synology NAS the data once determined. I think this will help to find the problem.

strausmann commented 2 years ago

For my Docker Node running on a Raspberry PI, my configuration works. So a misconfiguration can be excluded. So it must be the docker.sock of the Synology NAS.

chetan commented 2 years ago

@strausmann not clear what's going on here, as the error appears to be coming from the traefik parsing code itself, not my code. Can you post the config for your nginx container and also for running traefik kop itself?

chetan commented 1 year ago

@strausmann looking at this again, I'm guessing you may have had an errant quote in your docker label, something like this:

    labels:
      - traefik.enable=true"

That could lead to the above error. You need to remove that " or or add another at the start so it looks like:

    labels:
      - "traefik.enable=true"

In any case, I'm closing this for now as it does not appear related to traefik-kop, however feel free to reopen if you are still having issues.