2024-01-05 22:58:30 +00:00
|
|
|
---
|
|
|
|
# hashistack configuration merging for vault
|
2024-01-06 14:50:51 +00:00
|
|
|
- name: "Merge listener configuration"
|
|
|
|
ansible.builtin.set_fact:
|
|
|
|
vault_listener_configuration: "{{
|
|
|
|
vault_listener_configuration |
|
|
|
|
combine((vault_enable_tls | bool) | ternary(vault_tls_listener_configuration, {})) |
|
|
|
|
combine(vault_extra_listener_configuration | default({}))
|
|
|
|
}}"
|
|
|
|
|
2024-01-05 22:58:30 +00:00
|
|
|
- name: "Merge service registration configuration"
|
2024-01-06 14:50:51 +00:00
|
|
|
vars:
|
|
|
|
_config_to_merge:
|
|
|
|
service_registration: "{{ vault_service_registration_configuration }}"
|
2024-01-05 22:58:30 +00:00
|
|
|
ansible.builtin.set_fact:
|
2024-01-06 14:50:51 +00:00
|
|
|
hashi_vault_configuration: "{{
|
|
|
|
hashi_vault_configuration |
|
|
|
|
combine(_config_to_merge)
|
|
|
|
}}"
|
2024-01-05 22:58:30 +00:00
|
|
|
when: vault_enable_service_registration
|
2024-01-06 14:50:51 +00:00
|
|
|
|
|
|
|
- name: "Merge plugins configuration"
|
|
|
|
vars:
|
|
|
|
_config_to_merge:
|
|
|
|
plugin_directory: "{{ vault_plugin_directory }}"
|
|
|
|
ansible.builtin.set_fact:
|
|
|
|
hashi_vault_configuration: "{{
|
|
|
|
hashi_vault_configuration |
|
|
|
|
combine(_config_to_merge)
|
|
|
|
}}"
|
|
|
|
when: vault_enable_plugins
|