Skip to content

Commit

Permalink
Update to latest version (#11)
Browse files Browse the repository at this point in the history
* Update to latest vaultwarden and web-vault

* Add CentOS Stream 10 and Fedora 41 to supported platforms

* Add automatic release workflow
  • Loading branch information
bcook254 authored Dec 22, 2024
1 parent 90711f5 commit 245c816
Show file tree
Hide file tree
Showing 8 changed files with 45 additions and 8 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,12 @@ jobs:
image: docker.io/geerlingguy/docker-ubuntu2204-ansible:latest
- name: debian12
image: docker.io/geerlingguy/docker-debian12-ansible:latest
- name: fedora41
image: docker.io/geerlingguy/docker-fedora41-ansible:latest
- name: fedora40
image: docker.io/geerlingguy/docker-fedora40-ansible:latest
- name: fedora39
image: docker.io/geerlingguy/docker-fedora39-ansible:latest
- name: centosstream10
image: ghcr.io/bcook254/docker-centosstream10-ansible:latest
- name: centosstream9
image: ghcr.io/bcook254/docker-centosstream9-ansible:latest
steps:
Expand All @@ -57,7 +59,7 @@ jobs:
env:
PLATFORM_NAME: ${{ matrix.platform.name }}
PLATFORM_IMAGE: ${{ matrix.platform.image }}
VAULTWARDEN_VERSION: '1.32.2'
VAULTWARDEN_VERSION: '1.32.7'
VAULTWARDEN_URL: ${{ secrets.VAULTWARDEN_URL }}
PY_COLORS: '1'
ANSIBLE_FORCE_COLOR: '1'
Expand Down
25 changes: 25 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,37 @@ name: Release
tags:
- '*'

defaults:
run:
working-directory: 'bcook254.vaultwarden'

jobs:

release:
name: Release
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check out the codebase.
uses: actions/checkout@v3
with:
path: 'bcook254.vaultwarden'

- name: Get tags.
id: tags
shell: bash
run: |
git fetch --tags origin
previous="$(git tag -l | sort -V --reverse | sed -n 2p)"
echo "PREVIOUS=$previous" >> $GITHUB_OUTPUT
- name: Create release.
uses: softprops/action-gh-release@v2
with:
body: |
**Full Changelog**: https://github.com/${{ github.repository }}/compare/${{ steps.tags.outputs.PREVIOUS }}...${{ github.ref_name }}
- name: Trigger a new import on Galaxy.
run: >-
ansible-galaxy role import --api-key ${{ secrets.GALAXY_API_KEY }}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ When using `vaultwarden_url`, an optional dictionary of headers may be given to

When enabled, this role will also download the patched web-vault files.

vaultwarden_web_vault_version: 2024.3.1
vaultwarden_web_vault_version: 2024.6.2c

The version of Vaultwarden Web Vault to be installed.

Expand Down
2 changes: 1 addition & 1 deletion defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ vaultwarden_web_vault_dir: "{{ vaultwarden_home_dir }}/web-vault"
vaultwarden_config_dir: /etc/vaultwarden
vaultwarden_config_file: "{{ vaultwarden_config_dir }}/vaultwarden.env"
vaultwarden_database_name: vaultwarden
vaultwarden_web_vault_version: 2024.6.2
vaultwarden_web_vault_version: 2024.6.2c
vaultwarden_enable_web_vault: true
vaultwarden_manage_config: false
4 changes: 2 additions & 2 deletions meta/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ galaxy_info:
- name: EL
versions:
- 9
- 10
- name: Fedora
versions:
- 38
- 39
- 40
- 41
- name: Debian
versions:
- bookworm
Expand Down
7 changes: 7 additions & 0 deletions molecule/default/molecule.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,13 @@ provisioner:
vaultwarden_url: "${VAULTWARDEN_URL}"
vaultwarden_url_checksum: "sha256:{{ vaultwarden_url }}.sha256"
host_vars:
centosstream10:
vaultwarden_packages:
- openssl
- ca-certificates
- curl-minimal
- mariadb-devel
- libpq
centosstream9:
vaultwarden_packages:
- openssl
Expand Down
2 changes: 1 addition & 1 deletion molecule/default/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
chdir: /usr/local/bin
changed_when: false
register: __vaultwarden_version
failed_when: __vaultwarden_version is not search(vaultwarden_version if vaultwarden_version | length > 0 else '1.32.2')
failed_when: __vaultwarden_version is not search(vaultwarden_version if vaultwarden_version | length > 0 else '1.32.7')

- name: Check if Vaultwarden web-vault is installed.
ansible.builtin.stat:
Expand Down
3 changes: 3 additions & 0 deletions templates/env.j2
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,9 @@ DOMAIN={{ vaultwarden_domain }}
{% if vaultwarden_allowed_iframe_ancestors is defined %}
ALLOWED_IFRAME_ANCESTORS={{ vaultwarden_allowed_iframe_ancestors }}
{% endif %}
{% if vaultwarden_allowed_connect_src is defined %}
ALLOWED_CONNECT_SRC="{{ vaultwarden_allowed_connect_src }}"
{% endif %}
{% if vaultwarden_login_ratelimit_seconds is defined %}
LOGIN_RATELIMIT_SECONDS={{ vaultwarden_login_ratelimit_seconds }}
{% endif %}
Expand Down

0 comments on commit 245c816

Please sign in to comment.