From 24abec416bc942abf0a3800bdaafaff7177cfcba Mon Sep 17 00:00:00 2001 From: mqus <8398165+mqus@users.noreply.github.com> Date: Wed, 1 May 2019 16:49:18 +0200 Subject: [PATCH] add update/uninstall instructions. --- Setup-as-a-systemd-service.md | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/Setup-as-a-systemd-service.md b/Setup-as-a-systemd-service.md index e928b95..4d6a60c 100644 --- a/Setup-as-a-systemd-service.md +++ b/Setup-as-a-systemd-service.md @@ -49,6 +49,24 @@ To enable autostart, run $ sudo systemctl enable bitwarden_rs.service ``` In the same way you can `stop`, `restart` and `disable` the service. +### Updating bitwarden_rs +After compiling the new version of bitwarden_rs, you can copy the compiled (new) binary and replace the existing (old) binary and then restart the service: +``` +$ sudo systemctl restart bitwarden_rs.service +``` +### Uninstalling bitwarden_rs +Before doing anything else, you should stop and disable the service: +``` +$ sudo systemctl disable --now bitwarden_rs.service +``` +Then you can delete the binary, the `.env` file, the web-vault folder (if installed) and the user data (if necessary). Remember to also remove specially created users,groups and firewall rules (if needed) and the systemd file. + +After removing the systemd file you should make systemd aware of it via: +``` +$ sudo systemctl daemon-reload +``` + +### Logging and status view If you want to see the logging output, run ``` $ journalctl -u bitwarden_rs.service @@ -57,5 +75,5 @@ or to see a more concise state of the service, run ``` $ systemctl status bitwarden_rs.service ``` - +### More information For more information on .service files, see the manpages of [systemd.service](https://www.freedesktop.org/software/systemd/man/systemd.service.html) and (for the security configuration) [systemd.exec](https://www.freedesktop.org/software/systemd/man/systemd.exec.html) \ No newline at end of file