From d7a6f530dd139402a8f7c2db3d9dd194e069a79a Mon Sep 17 00:00:00 2001 From: Teck Meng Date: Wed, 28 Feb 2024 15:53:26 +0800 Subject: [PATCH] Add user list configuration to README.md --- README.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 86cbeaf..0a4932e 100644 --- a/README.md +++ b/README.md @@ -20,4 +20,14 @@ This simple project uses Traefik as a reverse proxy to a Streamlit application a 3. `docker compose -f production.yml up --build -d --remove-orphans` ### Notes: - +```yaml +# Declaring the user list +# +# Note: when used in docker-compose.yml all dollar signs in the hash need to be doubled for escaping. +# To create user:password pair, it's possible to use this command: +# echo $(htpasswd -nB user) | sed -e s/\\$/\\$\\$/g +# +# Also note that dollar signs should NOT be doubled when they not evaluated (e.g. Ansible docker_container module). +labels: + - "traefik.http.middlewares.test-auth.basicauth.users=test:$$apr1$$H6uskkkW$$IgXLP6ewTrSuBkTrqE8wj/,test2:$$apr1$$d9hr9HBB$$4HxwgUir3HP4EsggP/QNo0" +``` \ No newline at end of file