Skip to content

Commit

Permalink
[database]: Add --protected-mode no flag to redis-chassis (sonic-ne…
Browse files Browse the repository at this point in the history
…t#21010)

Redis-chassis doesn't bind to the localhost address intentionally.
Because of this, Redis blocks TCP connections that are connecting to
non-loopback interface addresses when there's no password set (which is
the case for us) unless `--protected-mode no` is set. This has already
been done for docker-database, but now needs to be done for
docker-sonic-vs following the upgrade to Bookworm.

Therefore, in the supervisord.conf file, add `--protected-mode no` to
the arguments passed in for redis-chassis.

Signed-off-by: Saikrishna Arcot <sarcot@microsoft.com>
  • Loading branch information
saiarcot895 authored and VladimirKuk committed Jan 21, 2025
1 parent 866add7 commit e10efcd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion platform/vs/docker-sonic-vs/supervisord.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ stdout_logfile=syslog
stderr_logfile=syslog

[program:redis-chassis]
command=/bin/bash -c "{ [[ -s /var/lib/redis_chassis/dump.rdb ]] || rm -f /var/lib/redis_chassis/dump.rdb; } && mkdir -p /var/lib/redis_chassis && exec /usr/bin/redis-server /etc/redis/redis.conf --bind redis_chassis.server --port 6380 --unixsocket /var/run/redis/redis_chassis.sock --pidfile /var/run/redis/redis_chassis.pid --dir /var/lib/redis_chassis"
command=/bin/bash -c "{ [[ -s /var/lib/redis_chassis/dump.rdb ]] || rm -f /var/lib/redis_chassis/dump.rdb; } && mkdir -p /var/lib/redis_chassis && exec /usr/bin/redis-server /etc/redis/redis.conf --bind redis_chassis.server --port 6380 --protected-mode no --unixsocket /var/run/redis/redis_chassis.sock --pidfile /var/run/redis/redis_chassis.pid --dir /var/lib/redis_chassis"
priority=3
autostart=false
autorestart=false
Expand Down

0 comments on commit e10efcd

Please sign in to comment.