refactor(vpn): split JWT identity and OpenVPN certificate lifecycle
OpenVPN Ansible / Ansible Syntax Check (push) Successful in 43s
OpenVPN Ansible / Ansible Lint (push) Successful in 1m8s
OpenVPN Ansible / Deploy VPN Networking and OpenVPN (push) Successful in 3m32s
OpenVPN Ansible / Generate SBOM (push) Successful in 55s
OpenVPN Ansible / Scan SBOM with Trivy (push) Successful in 18s
OpenVPN Ansible / Ansible Syntax Check (push) Successful in 43s
OpenVPN Ansible / Ansible Lint (push) Successful in 1m8s
OpenVPN Ansible / Deploy VPN Networking and OpenVPN (push) Successful in 3m32s
OpenVPN Ansible / Generate SBOM (push) Successful in 55s
OpenVPN Ansible / Scan SBOM with Trivy (push) Successful in 18s
- Add a dedicated role and workflow to generate VPN JWT identities and export public keys - Run identity preparation automatically for VPN nodes awaiting OpenBao registration - Gate OpenVPN and PKI setup until each node is registered - Split PKI setup into runtime, configuration, service, and initial certificate tasks - Restore TAP and bridge attachment after OpenVPN restarts - Remove bundled server certificate and private key
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
---
|
||||
- name: Install OpenBao CLI
|
||||
ansible.builtin.import_role:
|
||||
name: openbao_cli
|
||||
- name: Install OpenVPN PKI runtime dependencies
|
||||
ansible.builtin.apt:
|
||||
name:
|
||||
- openssl
|
||||
- jq
|
||||
- python3
|
||||
- util-linux
|
||||
state: present
|
||||
update_cache: true
|
||||
cache_valid_time: 3600
|
||||
- name: Calculate deployed company VPN Root CA fingerprint
|
||||
ansible.builtin.command:
|
||||
argv:
|
||||
- openssl
|
||||
- x509
|
||||
- -in
|
||||
- "{{ openvpn_pki_deployed_ca_source }}"
|
||||
- -noout
|
||||
- -fingerprint
|
||||
- -sha256
|
||||
register: openvpn_pki_company_ca_fingerprint
|
||||
changed_when: false
|
||||
- name: Normalize deployed company VPN Root CA fingerprint
|
||||
ansible.builtin.set_fact:
|
||||
openvpn_pki_company_ca_fingerprint_value: "{{ openvpn_pki_company_ca_fingerprint.stdout | regex_replace('^.*=', '') | replace(':', '') | upper }}"
|
||||
Reference in New Issue
Block a user