Skip to content
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

Reverse Proxy with Redis Stack only (Solution) #9

Open
luc4t opened this issue Apr 18, 2024 · 0 comments
Open

Reverse Proxy with Redis Stack only (Solution) #9

luc4t opened this issue Apr 18, 2024 · 0 comments

Comments

@luc4t
Copy link

luc4t commented Apr 18, 2024

After some trial and error I found a solution if you only want to run Redis Stack (which also has its built in Insight web interface):

Docker compose yml:

services:
redis-stack:
image: redis/redis-stack:latest
networks:
- redis-network

nginx-basicauth:
image: nginx
volumes:
- ./nginx-basic-auth.conf.template:/etc/nginx/templates/nginx-basic-auth.conf.template
ports:
- "${NGINX_PORT:-8001}:${NGINX_PORT:-8001}"
environment:
- FORWARD_HOST=redis-stack
- FORWARD_PORT=8001
- NGINX_PORT=${NGINX_PORT:-8001}
- BASIC_USERNAME=${BASIC_USERNAME:-redis}
- BASIC_PASSWORD=${BASIC_PASSWORD:-password}
command:
- bash
- -c
- |
printf "$$BASIC_USERNAME:$$(openssl passwd -1 $$BASIC_PASSWORD)\n" >> /etc/nginx/.htpasswd
/docker-entrypoint.sh nginx -g "daemon off;"
depends_on:
- redis-stack
networks:
- redis-network

networks:
redis-network:
driver: bridge

nginx-basic-auth.conf.template is the same

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant