vw_small

Hardened fork of Vaultwarden (https://github.com/dani-garcia/vaultwarden) with fewer features.
git clone https://git.philomathiclife.com/repos/vw_small
Log | Files | Refs | README

commit 64ac81b9ee740d6f430458fd609c002594363feb
parent 7c316fc19a1d9e4e8d14c5d79748dc30733f41b5
Author: Daniel GarcĂ­a <dani-garcia@users.noreply.github.com>
Date:   Fri, 29 Jun 2018 14:47:23 +0200

Added unofficial note and better organized the README file

Diffstat:
MREADME.md | 77++++++++++++++++++++++++++++-------------------------------------------------
1 file changed, 28 insertions(+), 49 deletions(-)

diff --git a/README.md b/README.md @@ -1,53 +1,31 @@ -## Easy setup (Docker) -Install Docker to your system and then, from the project root, run: -```sh -# Build the docker image: -docker build -t dani/bitwarden_rs . - -# Run the docker image with a docker volume: -docker volume create bw_data -docker run --name bitwarden_rs -t --init --rm --mount source=bw_data,target=/data -p 8000:80 dani/bitwarden_rs -``` - -#### Other possible Docker options - -To run the container in the background, add the `-d` parameter. - -To check the logs when in background, run `docker logs bitwarden_rs` - -To stop the container in background, run `docker stop bitwarden_rs` - -To make sure the container is restarted automatically, add the `--restart unless-stopped` parameter - -To run the image with a host bind, change the `--mount` parameter to: -``` ---mount type=bind,source=<absolute_path>,target=/data -``` -Where <absolute_path> is an absolute path in the hosts file system (e.g. C:\bitwarden\data) +# Bitwarden_RS +This project is an unofficial implementation of the [Bitwarden Core Server](https://github.com/bitwarden/core) written in [Rust](https://www.rust-lang.org/). -## How to compile bitwarden_rs -Install `rust nightly`, in Windows the recommended way is through `rustup`. +*(Note: This project is not associated with the [Bitwarden](https://bitwarden.com/) project nor 8bit Solutions LLC.)* -Install the `openssl` library, in Windows the best option is Microsoft's `vcpkg`, -on other systems use their respective package managers. +# Build/Run +This project can be built and deployed in two ways: -Then run: +## Docker Setup (Easy) +Install [Docker](https://www.docker.com/) to your system and then, from the project root, run: ```sh -cargo run -# or -cargo build -``` +# Build the docker image: +docker build -t bitwarden_rs . -## How to install the web-vault locally -If you're using docker image, you can just update `VAULT_VERSION` variable in Dockerfile and rebuild the image. +# Run the docker image with a docker volume: +docker run --name bitwarden_rs -t --rm -v bw_data:/data -p 80:80 bitwarden_rs +``` +Then visit [http://localhost:80](http://localhost:80) -Install `node.js` and either `yarn` or `npm` (usually included with node) +## Manual Setup (Advanced) +### Dependencies +- `Rust nightly` (strongly recommended to use [rustup](https://rustup.rs/)) +- `OpenSSL` (should be available in path, install through your system's package manager or use the [prebuilt binaries](https://wiki.openssl.org/index.php/Binaries)) +- `NodeJS` (required to build the web-vault, (install through your system's package manager or use the [prebuilt binaries](https://nodejs.org/en/download/)) -Clone the web-vault outside the project: -``` -git clone https://github.com/bitwarden/web.git web-vault -``` +### Install the web-vault +Download the latest official release from the [releases page](https://github.com/bitwarden/web/releases) and extract it. Modify `web-vault/settings.Production.json` to look like this: ```json @@ -62,20 +40,21 @@ Modify `web-vault/settings.Production.json` to look like this: } ``` -Then, run the following from the `web-vault` dir: +Then, run the following from the `web-vault` directory: ```sh -# With yarn (recommended) -yarn -yarn gulp dist:selfHosted - -# With npm npm install npx gulp dist:selfHosted ``` Finally copy the contents of the `web-vault/dist` folder into the `bitwarden_rs/web-vault` folder. -## How to recreate database schemas +### Running +```sh +cargo run +``` +Then visit [http://localhost:80](http://localhost:80) + +## How to recreate database schemas (for developers) Install diesel-cli with cargo: ```sh cargo install diesel_cli --no-default-features --features sqlite-bundled