r/bitwarden_rs: Remove dangling container at start

If the *vaultwarden* service terminates unexpectedly, e.g. due to a
power loss, `podman` may not successfully remove the container.  We
therefore need to try to delete it before starting it again, or `podman`
will exit with an error because the container already exists.
btop
Dustin 2022-08-22 20:06:02 -05:00
parent 4511d5447e
commit 1834f9a108
1 changed files with 1 additions and 0 deletions

View File

@ -4,6 +4,7 @@ Description=Vaultwarden API server
[Service] [Service]
Type=notify Type=notify
NotifyAccess=all NotifyAccess=all
ExecStartPre=-/usr/bin/podman container rm --force --ignore vaultwarden
ExecStart=/usr/bin/podman run \ ExecStart=/usr/bin/podman run \
--pull never \ --pull never \
--sdnotify=conmon --cgroups=no-conmon \ --sdnotify=conmon --cgroups=no-conmon \