Skip to content

Commit 685ea79

Browse files
committed
Add api endpoints for bitwarden/vaultwarden
1 parent 1571247 commit 685ea79

4 files changed

Lines changed: 44 additions & 4 deletions

bitwarden.subdomain.conf.sample

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Version 2023/02/05
1+
## Version 2023/02/13
22
# make sure that your bitwarden container is named bitwarden
33
# make sure that your dns has a cname set for bitwarden
44
# set the environment variable WEBSOCKET_ENABLED=true on your bitwarden container
@@ -68,6 +68,16 @@ server {
6868

6969
}
7070

71+
location ~ (/bitwarden)?/api {
72+
include /config/nginx/proxy.conf;
73+
include /config/nginx/resolver.conf;
74+
set $upstream_app bitwarden;
75+
set $upstream_port 80;
76+
set $upstream_proto http;
77+
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
78+
79+
}
80+
7181
location ~ (/bitwarden)?/notifications/hub {
7282
include /config/nginx/proxy.conf;
7383
include /config/nginx/resolver.conf;

bitwarden.subfolder.conf.sample

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Version 2023/02/05
1+
## Version 2023/02/13
22
# make sure that your bitwarden container is named bitwarden
33
# make sure that bitwarden is set to work with the base url /bitwarden/
44
## Environmental Variable DOMAIN=https://<DOMAIN>/bitwarden must be set in bitwarden container including subfolder.
@@ -54,6 +54,16 @@ location ~ (/bitwarden)?/admin {
5454

5555
}
5656

57+
location ~ (/bitwarden)?/api {
58+
include /config/nginx/proxy.conf;
59+
include /config/nginx/resolver.conf;
60+
set $upstream_app bitwarden;
61+
set $upstream_port 80;
62+
set $upstream_proto http;
63+
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
64+
65+
}
66+
5767
location ~ (/bitwarden)?/notifications/hub {
5868
include /config/nginx/proxy.conf;
5969
include /config/nginx/resolver.conf;

vaultwarden.subdomain.conf.sample

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Version 2023/02/05
1+
## Version 2023/02/13
22
# make sure that your vaultwarden container is named vaultwarden
33
# make sure that your dns has a cname set for vaultwarden
44
# set the environment variable WEBSOCKET_ENABLED=true on your vaultwarden container
@@ -68,6 +68,16 @@ server {
6868

6969
}
7070

71+
location ~ (/vaultwarden)?/api {
72+
include /config/nginx/proxy.conf;
73+
include /config/nginx/resolver.conf;
74+
set $upstream_app vaultwarden;
75+
set $upstream_port 80;
76+
set $upstream_proto http;
77+
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
78+
79+
}
80+
7181
location ~ (/vaultwarden)?/notifications/hub {
7282
include /config/nginx/proxy.conf;
7383
include /config/nginx/resolver.conf;

vaultwarden.subfolder.conf.sample

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
## Version 2023/02/05
1+
## Version 2023/02/13
22
# make sure that your vaultwarden container is named vaultwarden
33
# make sure that vaultwarden is set to work with the base url /vaultwarden/
44
## Environmental Variable DOMAIN=https://<DOMAIN>/vaultwarden must be set in vaultwarden container including subfolder.
@@ -54,6 +54,16 @@ location ~ (/vaultwarden)?/admin {
5454

5555
}
5656

57+
location ~ (/vaultwarden)?/api {
58+
include /config/nginx/proxy.conf;
59+
include /config/nginx/resolver.conf;
60+
set $upstream_app vaultwarden;
61+
set $upstream_port 80;
62+
set $upstream_proto http;
63+
proxy_pass $upstream_proto://$upstream_app:$upstream_port;
64+
65+
}
66+
5767
location ~ (/vaultwarden)?/notifications/hub {
5868
include /config/nginx/proxy.conf;
5969
include /config/nginx/resolver.conf;

0 commit comments

Comments
 (0)