Page is not loading correctly when using alternate base dir #1486

Closed
opened 2025-10-09 17:17:01 +03:00 by OVERLORD · 0 comments
Owner

Originally created by @ahaw on GitHub.

Subject of the issue

Bitwarden doesnt load when using alternate base pathes.
When I set domain to 'example.com/subdir' it loads the page but when the browser is trying to load resources it's ignoring basepath. The url of file is: "testing.test/app/polyfills.c9c57acc9b845fdb9052.js" instead of "testing.test/bitwarden/app/polyfills.c9c57acc9b845fdb9052.js"

Your environment

  • Bitwarden_rs version: bitwardenrs/server:alpine
  • Install method: docker-compose
  • Clients used: Latest chrome and firefox
  • Reverse proxy and version: traefik:latest
  • Other relevant information:

Steps to reproduce

Use alternate base dir in config and open bitwarden page.

Expected behaviour

it should load resources using basepath eg: testing.test/bitwarden/app/polyfills.c9c57acc9b845fdb9052.js

Actual behaviour

It ignoring basepath testing.test/app/polyfills.c9c57acc9b845fdb9052.js

Relevant logs

My docker configuration:
my config:
bitwarden:
container_name: bitwarden-test
image: bitwardenrs/server:alpine
restart: always
volumes:
- ./bitwarden/:/data/
ports:
- '29083:80'
env_file: .env
environment:
SIGNUPS_ALLOWED: "true"
DOMAIN: "http://testing.test/bitwarden"
labels:
- "traefik.enable=true"
- "traefik.http.routers.bitwarden.tls=false"
- "traefik.http.routers.bitwarden.rule=Host(testing.test) && PathPrefix(/bitwarden)"
- "traefik.http.routers.bitwarden.entrypoints=web"

Originally created by @ahaw on GitHub. ### Subject of the issue Bitwarden doesnt load when using alternate base pathes. When I set domain to 'example.com/subdir' it loads the page but when the browser is trying to load resources it's ignoring basepath. The url of file is: "testing.test/app/polyfills.c9c57acc9b845fdb9052.js" instead of "testing.test/bitwarden/app/polyfills.c9c57acc9b845fdb9052.js" ### Your environment * Bitwarden_rs version: bitwardenrs/server:alpine * Install method: docker-compose * Clients used: Latest chrome and firefox * Reverse proxy and version: traefik:latest * Other relevant information: ### Steps to reproduce Use alternate base dir in config and open bitwarden page. ### Expected behaviour it should load resources using basepath eg: testing.test/bitwarden/app/polyfills.c9c57acc9b845fdb9052.js ### Actual behaviour It ignoring basepath testing.test/app/polyfills.c9c57acc9b845fdb9052.js ### Relevant logs <!-- Share some logfiles, screenshots or output of relevant programs with us. --> My docker configuration: my config: bitwarden: container_name: bitwarden-test image: bitwardenrs/server:alpine restart: always volumes: - ./bitwarden/:/data/ ports: - '29083:80' env_file: .env environment: SIGNUPS_ALLOWED: "true" DOMAIN: "http://testing.test/bitwarden" labels: - "traefik.enable=true" - "traefik.http.routers.bitwarden.tls=false" - "traefik.http.routers.bitwarden.rule=Host(`testing.test`) && PathPrefix(`/bitwarden`)" - "traefik.http.routers.bitwarden.entrypoints=web"
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/vaultwarden#1486