-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Domain URL configuration results in 404 #1694
Comments
It kinda looks like you manually changed the If you want to change the domain i suggest to use the |
Hi, thx a lot for your Support! I have deleted the config and set env Variables but it's still the same behavior. When I set the domain env variable it comes up with the same error message. I have set -e LOG_LEVEL debug but it does not show up in the admin panel. Do you have some more tipps where to search? |
Does the changed setting not appear in the support string? All the logs are going to a file in the data folder by default. The file is called vaultwarden.log Also check the logs of the reverse proxy you use. |
I have set all parameters as docker env variables and everything shows up in the support string ... except log_file "log_file": null, |
The try to use |
Thx a lot. Any hint how to debug further? Thx a lot |
I faced a similiar Problem when deploying vaultwarden (still bitwarden_rs back then) behind an reverse proxy using an apache und CentOS. As far as i understand your configuration correctly you still let vaultwarden handle the ssl encryption, right? Client <-> Proxy = SSL Encrypted This should still be fine from a security perspective as far as i know and this is also referrd to in the wiki: "Note that when you put vaultwarden behind a reverse proxy, the connections between the reverse proxy and vaultwarden are typically assumed to be going through a secure private network, and thus do not need to be encrypted. The examples below assume you are running in this configuration, in which case you should not enable the HTTPS functionality built into vaultwarden (i.e., you should not set the ROCKET_TLS environment variable). If you do, connections will fail since the reverse proxy is using HTTP to connect to vaultwarden, but you're configuring vaultwarden to expect HTTPS." |
Hi Bokkabonga, However, I will try to disable ROCKET_TLS and check if the problem is caused by this setting. Thx a lot |
I have removed the ROCLKET_TLS Settings and the problem remain: if the domain setting is present, the server responds 404 |
Can you show us your Port mapping for the Docker Container? Or did i miss it in your original post? |
I have mapped: |
How excactly did you map this in your Docker-Compose? I remember someone facing a similiar problem in the forum who fixed it by changing his port mapping from: Ports:
To: Ports:
I´m not sure however if this is a possible solution for you, but might me worth a shot. |
hi, thx |
Ah Sorry if this was misleading. I was rather reffering to adding 127.0.0.1 to the mapping, not changing the Port! |
So this is my docker port mapping, which one do you propose to bind to localhost? "port_bindings" : [ |
If i understand this correctly i would suggest the following: "port_bindings" : [ |
thx for the tip ... but it doesnt wortk how can i troubleshoot this, the debug log doesn't help. what can i do within the container? |
You might want to set the Log_Level env to "debug" or even "trace" to get more detailed logfiles. |
I'm seeing the same issue, when I configure my url to be https://example.com/bitwarden/ rocket seems to generate bitwarden/api/xxx routes however the normal routes should still be in place because I have bitwarden running on http://0.0.0.:8000 and have it behind an nginx proxy that makes it available at https://example.com/bitwarden/ setting the url in the config to https://example.com/ makes bitwarden work, however the admin interface then does not work. So at the moment I have the workaround but this makes the admin interface not work, which I actually need to work... is there a way to set domain_origin in the config file? |
You can't mix/match different entry-points. We need the full actual URL for all items to work. We need to full URL because of e-mails which are sent which need that. |
@BlackDex Sure, I understand, that is exactly what I am trying to do, however, it doesn't work. If I put
it shoudn't put the So that configuration gives a 404 Are you saying I should then configure the reverse proxy to handle request to I don't have a mail server installed, so the urls in the mails are not important to me at the moment. If I put |
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
FIRST OF ALL THX A LOT FOR YOUR GREAT PROJECT!!!
Subject of the issue
I can start valutwarden successfully with the default "http://localhost" domain URL setting .
When it is running I can configure the domain url in the admin portal to use my proxy's real name https://foo.bar/bitwarden.
Valutwarden is then working perfect, 2FA mails contain the right urls, all clients connect successfully.
When I restart the docker container, I get the following error and the docker instance does not work:
"404: Not Found
The requested resource could not be found.
Rocket"
bitwarden.log
[2021-05-12 19:41:51.859][start][INFO] Rocket has launched from https://0.0.0.0:80
[2021-05-12 19:41:54.274][request][INFO] GET /admin/
[2021-05-12 19:41:54.274][response][INFO] 404 Not Found
When I disable the domain setting in config.json I can restart and set the url again through the admin panel. Everything works again. So everything is perfect, except I cannot reboot without getting stuck.
Is there some startup routine that checks the ssl cert or domain url?
I have tried to configure log_level=debug & EXTENDED_LOGGING=true but cannot generate any debug logging on the issue.
Thx a lot and looking foreward for your help!
Deployment environment
Webserver in the internet, running with apache as proxy for domain https://foo.bar/bitwarden, default ssl port 443. Letsencrypt SSL certs.
Port forwarding from the webserver to my local (ISP) synology with docker (443 to 5555)
Vaultwarden running as docker image, port mapping 80 -> 5555. Rocket_TLS certs copy of the webserver installed
Install method: Docker image on synology
Clients used: mobile, firefox
Reverse proxy and version:
Server version: Apache/2.4.6 (CentOS)
Server built: Nov 16 2020 16:18:20
Other relevant details:
Your environment (Generated via diagnostics page)
Config (Generated via diagnostics page)
docker env variables:
"ROCKET_TLS" = "{certs="/ssl/live/foo.bar/fullchain.pem",key="/ssl/live/foo.bar/privkey.pem"}"
"ROCKET_LIMITS", "{json=104857600}"
Docker volumes
/ssl -> points to a copy of the webservers certs
/data
The text was updated successfully, but these errors were encountered: