standalone executable behind nginx? #207

Closed
opened 2026-02-04 18:29:06 +03:00 by OVERLORD · 3 comments
Owner

Originally created by @Geobert on GitHub (Jan 23, 2019).

Hi,

I'm a software engineer but I'm quite weak in the server admin stuff which I only do on my hobby VPS.

That's why I don't have any idea on how to setup bitwarden_rs behind my existing nginx.

I tried to set up ROCKET_ADDRESS=127.0.0.1 and port to 8000, launch bitwarden_rs, and in nginx config:

server {
        listen          80;
        server_name     bw.mydomain.com;
        location / {
          proxy_pass http://127.0.0.1:8000;
          proxy_set_header Host             $host;
          proxy_set_header X-Real-IP        $remote_addr;
          proxy_set_header X-Forwarded-For  $proxy_add_x_forwarded_for;
        }
}

but when accessing bw.mydomain.com, it does not work and redirect me to mydomain.com

I'm trying to get it running without HTTPS first to get my certificate through letsencrypt and certbot.

What am I missing?

Regards

EDIT: just tried bw.mydomain.com/admin, it's working… ^^' I'm really a noob

Originally created by @Geobert on GitHub (Jan 23, 2019). Hi, I'm a software engineer but I'm quite weak in the server admin stuff which I only do on my hobby VPS. That's why I don't have any idea on how to setup bitwarden_rs behind my existing nginx. I tried to set up `ROCKET_ADDRESS=127.0.0.1` and port to 8000, launch bitwarden_rs, and in nginx config: ``` server { listen 80; server_name bw.mydomain.com; location / { proxy_pass http://127.0.0.1:8000; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; } } ``` but when accessing bw.mydomain.com, it does not work and redirect me to mydomain.com I'm trying to get it running without HTTPS first to get my certificate through letsencrypt and certbot. What am I missing? Regards EDIT: just tried bw.mydomain.com/admin, it's working… ^^' I'm really a noob
Author
Owner

@mprasil commented on GitHub (Jan 23, 2019):

Is it possible you have a redirect from http to https that is doing the redirect to top domain?

@mprasil commented on GitHub (Jan 23, 2019): Is it possible you have a redirect from http to https that is doing the redirect to top domain?
Author
Owner

@Geobert commented on GitHub (Jan 23, 2019):

I have but for the top domain only, not for bw.mydomain.com
Maybe the rules from top domain are overriding?

@Geobert commented on GitHub (Jan 23, 2019): I have but for the top domain only, not for bw.mydomain.com Maybe the rules from top domain are overriding?
Author
Owner

@mprasil commented on GitHub (Jan 23, 2019):

Sounds like that yeah. bitwarden_rs doesn't do any redirects on its own.

@mprasil commented on GitHub (Jan 23, 2019): Sounds like that yeah. bitwarden_rs doesn't do any redirects on its own.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/vaultwarden#207