From af69606bea7afb533ad2b46e645d85cb74f88f84 Mon Sep 17 00:00:00 2001 From: Jean-Christophe BEGUE Date: Tue, 11 Sep 2018 23:25:14 +0200 Subject: [PATCH] Documentation for SMTP and password hint configuration --- README.md | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/README.md b/README.md index aa0790a8..3730e159 100644 --- a/README.md +++ b/README.md @@ -22,6 +22,8 @@ _*Note, that this project is not associated with the [Bitwarden](https://bitward - [icons cache](#icons-cache) - [Changing the API request size limit](#changing-the-api-request-size-limit) - [Changing the number of workers](#changing-the-number-of-workers) + - [SMTP configuration](#smtp-configuration) + - [Password hint display](#password-hint-display) - [Other configuration](#other-configuration) - [Building your own image](#building-your-own-image) - [Building binary](#building-binary) @@ -248,6 +250,36 @@ docker run -d --name bitwarden \ mprasil/bitwarden:latest ``` +### SMTP configuration + +You can configure bitwarden_rs to send emails via a SMTP agent: + +```sh +docker run -d --name bitwarden \ + -e SMTP_HOST= \ + -e SMTP_PORT=587 \ + -e SMTP_SSL=true \ + -e SMTP_USERNAME= \ + -e SMTP_PASSWORD= \ + -v /bw-data/:/data/ \ + -p 80:80 \ + mprasil/bitwarden:latest +``` + +When `SMTP_SSL` is set to `true`(this is the default), only TLSv1.1 and TLSv1.2 protocols will be accepted and `SMTP_PORT` will default to `587`. If set to `false`, `SMTP_PORT` will default to `25` and the connection won't be encrypted. This can be very insecure, use this setting only if you know what you're doing. + +### Password hint display + +Usually, password hints are sent by email. But as bitwarden_rs is made with small or personal deployment in mind, hints are also available from the password hint page, so you don't have to configure an email service. If you want to disable this feature, you can use the `SHOW_PASSWORD_HINT` variable: + +```sh +docker run -d --name bitwarden \ + -e SHOW_PASSWORD_HINT=false \ + -v /bw-data/:/data/ \ + -p 80:80 \ + mprasil/bitwarden:latest +``` + ### Other configuration Though this is unlikely to be required in small deployment, you can fine-tune some other settings like number of workers using environment variables that are processed by [Rocket](https://rocket.rs), please see details in [documentation](https://rocket.rs/guide/configuration/#environment-variables).