i dont want to secure a secondary container, but instead protect a served folder locally like this: ``` server { server_name example.com; root /var/www/web_root/; index index.html; auth_basic "Restricted"; auth_basic_user_file auth.htpasswd; } ``` any way we can make this happen? currently its really just a proxy (resulting in an endless loop) when started with localhost: `FORWARD_HOST=127.0.0.1` ``` server { listen 80 default_server; location / { auth_basic "Restricted"; auth_basic_user_file auth.htpasswd; proxy_pass http://127.0.0.1:80; proxy_read_timeout 900; } } ``` currently i am solving it like this: ```conf server { listen 80 default_server; auth_basic "Restricted"; auth_basic_user_file auth.htpasswd; root /usr/share/nginx/html; index index.html; } ``` ```Dockerfile FROM beevelop/nginx-basic-auth COPY html_files /usr/share/nginx/html COPY nginx.conf /opt/auth.conf ``` it works, but it would be cool if it works without local files and custom containers. Just an idea...
Activity