Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/guerzon/ansible-role-vaultwarden

Ansible role for Vaultwarden
https://github.com/guerzon/ansible-role-vaultwarden

ansible ansible-role passwords vaultwarden

Last synced: 2 months ago
JSON representation

Ansible role for Vaultwarden

Awesome Lists containing this project

README

        

ansible-role-vaultwarden
=========

[![Lint and Test](https://github.com/guerzon/ansible-role-vaultwarden/workflows/Lint%20and%20Test/badge.svg)](https://github.com/guerzon/ansible-role-vaultwarden/actions?query=workflow%3ALint%20and%20Test)
[![Release](https://github.com/guerzon/ansible-role-vaultwarden/workflows/Release/badge.svg)](https://github.com/guerzon/ansible-role-vaultwarden/actions?query=workflow%3ARelease)

Install and manage your Vaultwarden instances using Ansible.

Requirements
------------

None

Role Variables
--------------

Refer to the defaults file (`defaults/main.yml`) for the complete details. The following is an example configuration.

Specify the web vault and API server versions, and run Vaultwarden as a specific user:

```yaml
web_vault_version: "2024.6.2c-1.7"
api_server_version: "1.32.2-2.2"
appuser: "vault"
```

Specify the database settings:

```yaml
database_url: "postgresql://appuser:[email protected]/vaultwardenprod"
```

Configure push notifications:

```yaml
push_enabled: "true"
push_installation_id: "CHANGEME"
push_installation_key: "CHANGEME"
```

General settings:

```yaml
domain: "https://pass.homelabnet.lcl"
signups_allowed: "true"
signups_verify: "true"
signups_domains_whitelist: "homelabnet.lcl"
invitations_allowed: "true"
invitation_org_name: "HomeLab Corp"
```

Advanced settings:

```yaml
admin_token: "CHANGEME"
disable_admin_token: "false"
```

Ensure emails are sent:

```yaml
smtp_host: "smtp.gmail.com"
smtp_from: "[email protected]"
smtp_from_name: "Vault Administrator"
smtp_username: "[email protected]"
smtp_password: "SecurePassword"
smtp_security: "starttls"
```

Set custom listening port:

```yaml
rocket_port: "5000"
```

Dependencies
------------

None

Example Playbook
----------------

Minimal installation example using a SQLite database:

```yaml
- hosts: all
roles:
- vaultwarden
```

Specify the domain name and custom Rocket port:

```yaml
- hosts: all
vars:
domain: "https://vaultwarden.homelabnet.lcl"
rocket_port: "8000"
roles:
- vaultwarden
```

Supported Platforms
-------

Currently, the following are supported. Additional distros will be supported in the future.

- Red Hat Enterprise Linux 9
- Rocky Linux 9
- Fedora 40

License
-------

[MIT](./LICENSE)

Author Information
------------------

This Ansible role is managed by [Lester Guerzon](https://medium.com/@linuxheadafterhours).