-
Notifications
You must be signed in to change notification settings - Fork 4.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Redis provider is not working #6210
Labels
Projects
Milestone
Comments
ldez
added
area/provider/redis
contributor/waiting-for-feedback
kind/bug/possible
a possible bug that needs analysis before it is confirmed or fixed.
and removed
status/0-needs-triage
labels
Jan 21, 2020
@ldez Here is the version: "3.7"
services:
site1:
image: nginx
volumes:
- ./site1:/usr/share/nginx/html
site2:
image: nginx
volumes:
- ./site2:/usr/share/nginx/html
storage:
sysctls:
net.core.somaxconn: 1024
image: redis
command: --appendonly yes --save 60 1
ports:
- 6379:6379
volumes:
- ./storage:/data
router:
depends_on:
- storage
image: containous/traefik:experimental-master
command: --api.insecure=true --providers.redis --providers.redis.endpoints=storage:6379 --log --log.level=INFO
ports:
- 80:80
- 8080:8080 Then I start Redis first:
Then I create the config:
Starting the rest of the services and streaming logs:
What am I doing wrong? |
ldez
added
kind/bug/confirmed
a confirmed bug (reproducible).
and removed
contributor/waiting-for-feedback
kind/bug/possible
a possible bug that needs analysis before it is confirmed or fixed.
labels
Jan 21, 2020
I reproduce if I use the redis-cli to set values in the KV. The current value format is: {"Key":"traefik/http/routers/Router1/rule","Value":"Zm9vYmFy","LastIndex":318341026} instead of:
It's related to the the lib we use to manage KV: https://github.com/abronan/valkeyrie So I will try to fix this lib. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
What did you do?
Set up Redis, populated a simple dynamic configuration, then started
traefik
.This config works ok if using
etcd
instead of Redis.What did you expect to see?
Traefik working with the config from Redis.
What did you see instead?
No matter what I do
traefik
is unable to get any config from Redis. It either complains that it can't build the config because the key wasn't found (if the key starts with justtraefik
), or throws parsing errors (if it starts with/traefik
). I also described the issue here: https://community.containo.us/t/struggle-with-redis-in-current-master/4028Output of
traefik version
: (What version of Traefik are you using?)What is your environment & configuration (arguments, toml, provider, platform, ...)?
Redis latest version (
v5.0.7
).If applicable, please paste the log output in DEBUG level (
--log.level=DEBUG
switch)No slash in front of the key:
With slash in front of the key:
or
Obviously it tries to parse keys when the prefix starts with the slash, but this is inconsistent with
etcd
provider behavior.The text was updated successfully, but these errors were encountered: