29 lines
1.1 KiB
YAML
29 lines
1.1 KiB
YAML
---
|
|
- name: orientdb_certificates | Manage the Letsencrypt certificates
|
|
tags: ['orientdb', 'letsencrypt', 'orientdb_letsencrypt']
|
|
when: orientdb_ssl_enabled
|
|
block:
|
|
- name: orientdb_certificates | Create the acme hooks directory if it does not yet exist
|
|
ansible.builtin.file:
|
|
dest: "{{ letsencrypt_acme_services_scripts_dir }}"
|
|
state: directory
|
|
owner: root
|
|
group: root
|
|
mode: "0755"
|
|
- name: orientdb_certificates | Install a letsencrypt hook to update the orientdb certificate
|
|
ansible.builtin.template:
|
|
src: orientdb-letsencrypt-acme.sh.j2
|
|
dest: "{{ letsencrypt_acme_services_scripts_dir }}/orientdb"
|
|
owner: root
|
|
group: root
|
|
mode: "4555"
|
|
|
|
- name: orientdb_certificates | Remove the hook if letsencrypt is not used
|
|
tags: ['orientdb', 'letsencrypt', 'orientdb_letsencrypt']
|
|
when: not orientdb_letsencrypt_ssl_enabled
|
|
block:
|
|
- name: orientdb_certificates | Install a letsencrypt hook to update the orientdb certificate
|
|
ansible.builtin.file:
|
|
dest: "{{ letsencrypt_acme_services_scripts_dir }}/orientdb"
|
|
state: absent
|