Shared access to BWData?

Hi, wondering if anyone can help.

We are implementing a self hosted version of bitwarden in our organisation. We need high availability, so we have two servers in two different regions accessed via a load balancer.

We have a central MSSQL database and we have found in order to get both servers to work, you need to replicate the BWData folder between them. We are looking to make this more fluid, reason being, if you make changes to the setup, the organisation will then need to remember to copy the BWdata folder to the second server etc.

Current thoughts are to use an NFS based storage account to host the BWdata folder and then share it on both servers, has anyone done this? Can you offer any setup advice etc?

Thanks in advance,
Jamie

I have solved this issue now, if anyone else was interested then you could use these instructions below.

Instructions:https://learn.microsoft.com/en-us/azure/storage/blobs/network-file-system-protocol-support-how-to

  • Install the AZNFS mounting system, run the following command.
wget -O - -q https://github.com/Azure/AZNFS-mount/releases/latest/download/aznfs_install.sh | bash
  • Move or rename the bitwarden directory from /opt/bitwarden (renaming to bitwarden.old would suffice)

  • Make new bitwarden directory

sudo mkdir -p bitwarden
  • Mount the NFS share to /opt/bitwarden and make it persistent. In order to do this, you need to add an entry to the FSTAB file, located at /etc
cd /etc
sudo nano fstab
<yourstorageaccountname>.blob.core.windows.net:/<yourstorageaccountname/containername>  /opt/bitwarden    aznfs defaults,sec=sys,vers=3,nolock,proto=tcp,nofail,_netdev    0 0
  • Mount the NFS Share
mount /opt/bitwarden

Dont forget then to change the ownership of the /opt/bitwarden directory back to bitwarden and you should be good to go.