Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions deploy/docker/supervisord.conf
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ logfile_maxbytes=0
[program:redis]
; Loopback-only and password-protected. REDIS_PASSWORD is exported by
; entrypoint.sh from the mounted secret; the app must supply it to connect.
command=/usr/bin/redis-server --loglevel notice --bind 127.0.0.1 ::1 --requirepass "%(ENV_REDIS_PASSWORD)s" --dir /var/lib/redis
command=/usr/bin/redis-server --loglevel notice --bind 127.0.0.1 -::1 --requirepass "%(ENV_REDIS_PASSWORD)s" --dir /var/lib/redis
user=appuser ; Run redis as our non-root user
autorestart=true
priority=10
Expand All @@ -31,4 +31,4 @@ stdout_logfile_maxbytes=0
stderr_logfile=/dev/stderr ; Redirect gunicorn stderr to container stderr
stderr_logfile_maxbytes=0

# Optional: Add filebeat or other logging agents here if needed
# Optional: Add filebeat or other logging agents here if needed
4 changes: 2 additions & 2 deletions deploy/docker/tests/test_security_container_posture.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ class TestSupervisord:
def test_redis_requires_password(self, supervisord):
assert "--requirepass" in supervisord

def test_redis_bound_loopback(self, supervisord):
assert "--bind 127.0.0.1" in supervisord
def test_redis_bound_loopback_with_optional_ipv6(self, supervisord):
assert "--bind 127.0.0.1 -::1" in supervisord

def test_gunicorn_bind_is_env_driven(self, supervisord):
# entrypoint.sh resolves GUNICORN_BIND (loopback unless a credential).
Expand Down
Loading