Right way for an update (Vaultwarden) on Qnap Container Station

Right way for an update (Vaultwarden) on Qnap Container Station.

Hello dear community,

I am running a Vaultwarden Docker on a QNAP in the ContainerStation.

What is the right approach to update to the latest version and migrate all the old data (passwords, files, settings) with it?

Would anyone have help, I’m still struggling with containers.

Thanks for your time

Not super familiar with QNAP or their ContainerStation, but it appears they support LXC and Docker as you mentioned you are running within Docker.

All you should need to do is make sure your current container has a mounted volume, as this is where data from the container for passwords, file attachments, sends, and other config files live. By default this is kept in the /DATA folder inside the container, and usually ./vw-data outside the container.
This can be changed as needed, https://github.com/dani-garcia/vaultwarden/wiki/Changing-persistent-data-location

It is always good to have a separate backup of your important data, so prior to any upgrade I would always make sure you have a backup of your data and passwords.

Run a quick export on your vault and any organization collections, so even in a worst case scenario you have all your passwords. I would recommend exporting an unencrypted .json (this is independent of your vault user and account encryption keys and provides more information than .csv files)
Export to an encrypted data point such as a veracrypt container or similar.

If you have a volume for your container, then all your persistent data in the vaultwarden container is stored there. All you should need to do is update the vaultwarden image to the latest version or pull down the latest image with

docker pull vaultwarden/server:latest

Or however it would be updated in ContainerStation for your image, once you have the latest image from the docker repository, you should be able to stop the Vaultwarden container, delete if needed, and recreate the docker container with the new image, using all the same settings and volumes as the original.
See https://github.com/dani-garcia/vaultwarden/wiki/Updating-the-vaultwarden-image for more details and to get a better understanding of updating docker in general.

Notable mention, there is a repo which details Vaultwarden deployment in QNAP
You may check this to see if there are more specifics regarding upgrading from directly with ContainerStation

Hope this helps, cheers.

1 Like

Hello cksapp,

so it worked smoothly. Many thanks!

Can you please elaborate more exactly on the details - the sequence of steps that you did?