This fixes iOS app connection issues by properly responding to /.well-known/bitwarden/ endpoint which iOS clients use to identify the server.
31 lines
907 B
YAML
31 lines
907 B
YAML
apiVersion: v1
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: nginx-well-known-config
|
|
data:
|
|
default.conf: |
|
|
server {
|
|
listen 8080;
|
|
server_name _;
|
|
|
|
# Well-known endpoint for Bitwarden clients
|
|
location /.well-known/bitwarden/ {
|
|
add_header Content-Type application/json;
|
|
return 200 '{"object":"bitwarden-bitwarden-host","api":"https://vaultwarden.lotimmy.com"}';
|
|
}
|
|
|
|
# Forward all other requests to Vaultwarden
|
|
location / {
|
|
proxy_pass http://127.0.0.1:3000;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header X-Forwarded-Proto $scheme;
|
|
|
|
# WebSocket support
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
}
|
|
}
|