diff --git a/Using-the-MySQL-Backend.md b/Using-the-MySQL-Backend.md index cbfbe34..11b9932 100644 --- a/Using-the-MySQL-Backend.md +++ b/Using-the-MySQL-Backend.md @@ -2,7 +2,11 @@ To use the MySQL backend, first ensure you build the binary [with MySQL feature To run the binary or container ensure the ```DATABASE_URL``` environment variable is set (i.e. ```DATABASE_URL='mysql://:@mysql/bitwarden```) and ```ENABLE_DB_WAL``` is set to false ```ENABLE_DB_WAL='false'``` . -Example using docker +**Connection String Syntax:** +``` +DATABASE_URL=mysql://[[user]:[password]@]host[:port][/database] +``` +**Example using Docker:** ``` # Start a mysql container docker run --name mysql --net \ @@ -18,4 +22,11 @@ docker run -d --name bitwarden --net \ -e RUST_BACKTRACE=1 -e DATABASE_URL='mysql://:@mysql/bitwarden'\ -e ADMIN_TOKEN=\ -e ENABLE_DB_WAL='false' -``` \ No newline at end of file +``` + +**Example using Non-Docker MySQL Server:** + +``` +Server IP/Port 192.168.1.10:3306 UN: dbuser / PW: P@ssw0rd / DB: Bitwarden +mysql://dbuser:P@ssw0rd@192.168.1.10:3306/bitwarden +```