Open brandonfl opened 4 months ago
Hello,
I am trying to create a miniserve with basicauth by path, for example :
But
The CSS do not work as it try to get it from "url.com/CSS" but the access to "url.com/" is denied
Here how I am doing with traefik :
labels: # service traefik.enable: "true" traefik.http.services.miniserve.loadbalancer.server.port: "8080" # test traefik.http.routers.miniserve-test.rule: "Host(`url.com`) && PathPrefix(`/test`)" traefik.http.routers.miniserve-test.tls: "true" traefik.http.routers.miniserve-test.entrypoints: "web-secure" traefik.http.routers.miniserve-test.service: "miniserve" traefik.http.routers.miniserve-test.middlewares: "miniserve-test-auth, contentCompression@file, autodetectContenttype@file" traefik.http.middlewares.miniserve-test-auth.basicauth.removeheader: true traefik.http.middlewares.miniserve-test-auth.basicauth.users: "..." # toto traefik.http.routers.miniserve-toto.rule: "Host(`url.com`) && PathPrefix(`/toto`)" traefik.http.routers.miniserve-toto.tls: "true" traefik.http.routers.miniserve-toto.entrypoints: "web-secure" traefik.http.routers.miniserve-toto.service: "miniserve" traefik.http.routers.miniserve-toto.middlewares: "miniserve-toto-auth, contentCompression@file, autodetectContenttype@file" traefik.http.middlewares.miniserve-toto-auth.basicauth.removeheader: true traefik.http.middlewares.miniserve-toto-auth.basicauth.users: "..."
Is there a way to make the css file accessible to all path even if the / is not accessible ? Like having the CSS in relative path ?
Thanks in advance, BrandonFL
Hello,
Description
I am trying to create a miniserve with basicauth by path, for example :
But
Problem
The CSS do not work as it try to get it from "url.com/CSS" but the access to "url.com/" is denied
How to repro
Here how I am doing with traefik :
Spoiler
Possible solution
Is there a way to make the css file accessible to all path even if the / is not accessible ? Like having the CSS in relative path ?
Thanks in advance, BrandonFL