Bitwarden Docker Installation
Update: Bitwarden could not detect new and update password in browsers in most of cases. No matter how easy it can be used, without this auto detection feature, it is useless.
Bitwarden is an opensource password manager, can be self-hosted, and can be installed as docker container. It supports many browsers and OSes.
Steps
Create docker-compose.yaml
Create docker-compose.yaml, and make sure
- SIGNUPS_ALLOWED is 'true'
# docker-compose.yml
version: '3'
services:
bitwarden:
image: bitwardenrs/server
restart: always
ports:
- 8000:80
volumes:
- ./bw-data:/data
environment:
WEBSOCKET_ENABLED: 'true' # Required to use websockets
SIGNUPS_ALLOWED: 'true' # set to false to disable signups
Create
Run following command, in the directory contains docker-compose.yaml
docker-compose up -d
Configure HTTPS in NGINX
Without HTTPS, bitwarden doesn't allow new user registration.
Add following statements in server location definition.
server {
server_name nginx_host;
listen 443 ssl;
...
location /bw {
rewrite /bw(.*) /$1 break;
proxy_pass 'http://192.168.1.222:8000';
proxy_redirect off;
proxy_set_header Host $host;
}
...
}
Then the URL of bitwarden will be https://nginx_host/bw/
Register
Access https://nginx_host/bw/
, and register email and password.
Disable new user creation
- Destory old bitwarden instance
docker-compose down
- Update docker-compose.yaml file
SIGNUPS_ALLOWED: 'false';
- Recreate instance
docker-compose up -d
Trun on 2FA
In website, go to Settings => Two-step Login ...
Install clients
Go to bitwarden website to install.
References
Run Bitwarden Password Manager in Docker Container
Install and Deploy - Linux
The Best Password Managers to Secure Your Digital Life
Host your own FREE Password Manager with your Synology NAS
Install and Sync All of Your Devices
Connect Clients to your Instance
Request Hosting Installation Id & Key