version: "3.7" services: app_proxy: environment: APP_HOST: vaultwarden_server_1 APP_PORT: 8089 PROXY_AUTH_ADD: "false" server: image: vaultwarden/server:1.37.5@sha256:4fe17f415f90087377d37c755e0ea3cf189dcc6794e49cdd2a9adbb4937d9e1f user: "1000:1000" entrypoint: /bin/sh # Bitwarden Web Vault (v2026.4.1+) rejects non-HTTPS API and notification URLs. # Umbrel's Tor hidden service is served over http://*.onion, which Tor Browser # treats as a secure context. Patch only the copied web vault bundle so onion # access still works, while plain HTTP remains blocked for non-onion hosts. command: - -c - | set -e web_vault="/tmp/web-vault-patched" rm -rf "$$web_vault" cp -R /web-vault "$$web_vault" main_js="$$(ls "$$web_vault"/app/main.*.js)" grep -Fq '&&!this.platformUtilsService.isDev()' "$$main_js" sed -i 's/&&!this\.platformUtilsService\.isDev()/\&\&!this.platformUtilsService.isDev()\&\&!location.hostname.endsWith(".onion")/g' "$$main_js" grep -Fq '&&!this.platformUtilsService.isDev()&&!location.hostname.endsWith(".onion")' "$$main_js" export WEB_VAULT_FOLDER="$$web_vault" exec /start.sh restart: on-failure stop_grace_period: 1m volumes: - ${APP_DATA_DIR}/data:/data environment: ROCKET_PORT: 8089