Skip to content

Self hosting vaultwarden pw mgr#7365

Open
DHBR2 wants to merge 18 commits intodevelopfrom
self-hosting-vaultwarden-pw-mgr
Open

Self hosting vaultwarden pw mgr#7365
DHBR2 wants to merge 18 commits intodevelopfrom
self-hosting-vaultwarden-pw-mgr

Conversation

@DHBR2
Copy link
Collaborator

@DHBR2 DHBR2 commented Nov 19, 2025

Updated using Vaultwarden on Ubuntu 24.04 to replace existing documentation for using Vaultwarden Password Manager. All components update to latest version and switched from using a brittle version of Caddy to using NGINX for reverse proxy.

nmelehan-akamai and others added 8 commits September 10, 2025 16:39
Corrected typos in instructions for accessing Vaultwarden and NGINX configuration.
Updated notes and warnings to improve clarity and accuracy regarding Docker installation and configuration on Ubuntu 24.04.
There is no provision for "warnings" or "important" in this, just use "note" everywhere you need to call something out.
@netlify
Copy link

netlify bot commented Nov 19, 2025

Deploy Preview for nostalgic-ptolemy-b01ab8 ready!

Name Link
🔨 Latest commit 3155ef2
🔍 Latest deploy log https://app.netlify.com/projects/nostalgic-ptolemy-b01ab8/deploys/692604c29a9491000948f0b0
😎 Deploy Preview https://deploy-preview-7365--nostalgic-ptolemy-b01ab8.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link
Collaborator

@Rajakavitha1 Rajakavitha1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @DHBR2 and @nmelehan-akamai may be i am missing something. I was not successful in testing this guide. I have attached the output of the termial text so that you can see the steps that did not work for me.

Terminal Saved Output- vaultwarden.txt

Hi @DHBR2 and @nmelehan-akamai I am sorry that the terminal output that I shared earlier included all the output since i configured my new laptop including the git confgurations.
Here's the output that you might wamt to test for the vaultwarden.
valtwarden..pdf

Comment on lines +32 to +33
- Docker Engine with Docker Compose plugin (V2) installed
- NGINX installed (we'll configure it later to reverse proxy Vaultwarden)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I walked through the terminal output you shared. It looks like most of the early work was focused on getting your local macOS environment ready—developer tools, security policy, and Git authentication.
xcode-select: note: No developer tools were found
Application Prohibited: This application has been prohibited by security policy
Permission denied (publickey)
Password authentication is not supported for Git operations

Once those prerequisites were in place, Git behaved normally. The later part of the log shows a clean commit and push:

Writing objects: 100% (8/8)
To https://github.com/Rajakavitha1/docs.git
a7a2ccf..b83ebc5 rtx-rajie -> rtx-rajie

That sequence only happens when Git is fully configured and authenticated. So, the guide itself didn’t fail — the commands didn’t run in a ready environment until later:

Enumerating objects: 15, done.
Counting objects: 100% (15/15), done.
Delta compression using up to 8 threads
Compressing objects: 100% (7/7), done.
Writing objects: 100% (8/8), 620 bytes | 620.00 KiB/s, done.
remote: Resolving deltas: 100% (6/6), completed with 6 local objects.
To https://github.com/Rajakavitha1/docs.git
a7a2ccf..b83ebc5 rtx-rajie -> rtx-rajie

I didn’t see where a compute instance was created or where the guide’s steps were run inside that environment, so it looks like the testing didn’t reach that stage yet. Let me know if you want to walk through the instance setup together.

Regarding the prerequisites section: a common documentation convention is that prerequisites list only the conditions that must exist before a user begins a guide. Tools or packages that are installed within the guide — such as Docker CE, the Compose plugin, and NGINX — are typically included in the guided steps rather than in the prerequisites, to avoid implying that they must be installed ahead of time.

Comment on lines +43 to +57
Set the hostname:

```command
sudo hostnamectl set-hostname vaultwarden-test
```
Replace`vaultwarden-test` with the environment name you want.

Set the timezone:

List available timezones:
```command
timedatectl list-timezones
```
Then set your timezone (e.g., for Pacific Time):

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As a part of the Get Started instrucstions for hostname that the user sets is provided here. These are set before the the limited user or root user is created. We run the risk of the users creating two hostnames one as a root user as detailed here:
https://deploy-preview-7365--nostalgic-ptolemy-b01ab8.netlify.app/docs/products/compute/compute-instances/guides/set-up-and-secure/#set-the-timezone
https://deploy-preview-7365--nostalgic-ptolemy-b01ab8.netlify.app/docs/products/compute/compute-instances/guides/set-up-and-secure/#configure-a-custom-hostname

ANd the other the hostnames that the limited user (sudo user ) creates.

rajie@vault-warden:/srv/vaultwarden$ sudo hostnamectl set-hostname vaultwarden-test
rajie@vault-warden:/srv/vaultwarden$ hostname -f
vaultwarden-test
rajie@vault-warden:/srv/vaultwarden$ hostnamectl
 Static hostname: vaultwarden-test
       Icon name: computer-vm
         Chassis: vm 🖴
      Machine ID: d0e2ac542d4d4da48956903881db595e
         Boot ID: 45bd4a101bca488d926dff70705507d3
  Virtualization: kvm
Operating System: Ubuntu 24.04.4 LTS              
          Kernel: Linux 6.8.0-71-generic
    Architecture: x86-64
 Hardware Vendor: Linode
  Hardware Model: Compute Instance
Firmware Version: Not Specified
rajie@vault-warden:/srv/vaultwarden$ su hostname -f
su: user hostname does not exist or the user entry does not contain all the required fields
rajie@vault-warden:/srv/vaultwarden$ su root
Password: 
su: Authentication failure
rajie@vault-warden:/srv/vaultwarden$ su root
Password: 
root@vaultwarden-test:/srv/vaultwarden# hostnamectl
 Static hostname: vaultwarden-test
       Icon name: computer-vm
         Chassis: vm 🖴
      Machine ID: d0e2ac542d4d4da48956903881db595e
         Boot ID: 45bd4a101bca488d926dff70705507d3
  Virtualization: kvm
Operating System: Ubuntu 24.04.4 LTS              
          Kernel: Linux 6.8.0-71-generic
    Architecture: x86-64
 Hardware Vendor: Linode
  Hardware Model: Compute Instance
Firmware Version: Not Specified
root@vaultwarden-test:/srv/vaultwarden# su rajie
rajie@vaultwarden-test:/srv/vaultwarden$ hostnamectl
 Static hostname: vaultwarden-test
       Icon name: computer-vm
         Chassis: vm 🖴
      Machine ID: d0e2ac542d4d4da48956903881db595e
         Boot ID: 45bd4a101bca488d926dff70705507d3
  Virtualization: kvm
Operating System: Ubuntu 24.04.4 LTS              
          Kernel: Linux 6.8.0-71-generic
    Architecture: x86-64
 Hardware Vendor: Linode
  Hardware Model: Compute Instance
Firmware Version: Not Specified

Comment on lines +63 to +77
```command
hostnamectl
timedatectl
```
Expected output similar to:
```output
Static hostname: vaultserver
Operating System: Ubuntu 24.04 LTS
Architecture: x86-64

Local time: Wed 2025-11-05 09:45:00 PST
System clock synchronized: yes
NTP service: active
Time zone: America/Los_Angeles (PST, -0800)
```
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The output on ubuntu 24.04 is slightly different.

rajie@vaultwarden-test:/srv/vaultwarden$ hostnamectl
 Static hostname: vaultwarden-test
       Icon name: computer-vm
         Chassis: vm 🖴
      Machine ID: d0e2ac542d4d4da48956903881db595e
         Boot ID: 45bd4a101bca488d926dff70705507d3
  Virtualization: kvm
Operating System: Ubuntu 24.04.4 LTS              
          Kernel: Linux 6.8.0-71-generic
    Architecture: x86-64
 Hardware Vendor: Linode
  Hardware Model: Compute Instance
Firmware Version: Not Specified
rajie@vaultwarden-test:/srv/vaultwarden$ timedatectl
               Local time: Tue 2026-03-03 20:28:36 IST
           Universal time: Tue 2026-03-03 14:58:36 UTC
                 RTC time: Tue 2026-03-03 14:58:36
                Time zone: Asia/Kolkata (IST, +0530)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no
rajie@vaultwarden-test:/srv/vaultwarden$ 

Comment on lines +202 to +212
Step 7: How to Remove Legacy Docker Packages (if applicable)

If you previously installed docker.io, remove it with:
```command
sudo apt purge docker.io
```
If you installed older Docker CE packages, remove them with:
```command
sudo apt purge docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin docker-ce-rootless-extras
```
This ensures a clean environment for Vaultwarden and modern Compose workflows.Then follow the steps above (step 6) to install Docker CE. This guide is designed to help you recover safely and proceed with confidence.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: May be we can provide this at the begining of the section to ensure that the user gets a clean environment for Vaultwarden. This also ensures that the old packages not create issues before they begin the installation.

Comment on lines +272 to +276
Step 3: Configure Vaultwarden Environment Variables

This ensures Vaultwarden knows its domain and admin token. Change to the Vaultwarden directory if you are not already there:
```command
cd /home/your-username/vaultwarden
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We never created a vaultwarden directory yet.

rajie@vaultwarden-test:/$ cd /home/rajie/vaultwarden
bash: cd: /home/rajie/vaultwarden: No such file or directory
rajie@vaultwarden-test:/$ 

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To proceed further wit the testing i created the directory:

sudo mkdir /srv/vaultwarden
 sudo chmod go-rwx /srv/vaultwarden

Comment on lines +288 to +291
Step 4: Then restart Vaultwarden:
```command
docker compose down
docker compose up -d
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no compose file so this step did not work:

rajie@vaultwarden-test:/srv/vaultwarden$ cd ..
rajie@vaultwarden-test:/srv$ cd ..
rajie@vaultwarden-test:/$ cd /home/rajie/vaultwarden
bash: cd: /home/rajie/vaultwarden: No such file or directory
rajie@vaultwarden-test:/$ cd /srv/vaultwarden/
rajie@vaultwarden-test:/srv/vaultwarden$ sudo nano .env
[sudo] password for rajie: 
rajie@vaultwarden-test:/srv/vaultwarden$ docker compose down
no configuration file provided: not found
rajie@vaultwarden-test:/srv/vaultwarden$ docker compose up -d
no configuration file provided: not found
rajie@vaultwarden-test:/srv/vaultwarden$ 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants