Fix haproxy precheck when kolla_externally_managed_cert is used

Signed-off-by: Marc 'risson' Schmitt <marc.schmitt@risson.space>
Closes-Bug: #1940286
Change-Id: I647f8615e9fd0cc0db7c737ce4afbd1bdd0d40d4
(cherry picked from commit 0858d5487e)
This commit is contained in:
Marc 'risson' Schmitt 2021-08-16 19:43:12 +02:00 committed by Mark Goddard
parent 01583ba160
commit 30117a04ad
2 changed files with 8 additions and 4 deletions

View File

@ -47,17 +47,17 @@
register: haproxy_cert_file
changed_when: false
when:
- kolla_enable_tls_external | bool
- not kolla_externally_managed_cert | bool
- kolla_enable_tls_external | bool
- name: Fail if external haproxy certificate is absent
run_once: true
fail:
msg: "External haproxy certificate file is not found. It is configured via 'kolla_external_fqdn_cert'"
when:
- not kolla_externally_managed_cert | bool
- kolla_enable_tls_external | bool
- not haproxy_cert_file.stat.exists
- not kolla_externally_managed_cert | bool
- name: Checking if internal haproxy certificate exists
run_once: true
@ -67,17 +67,17 @@
register: haproxy_internal_cert_file
changed_when: false
when:
- kolla_enable_tls_internal | bool
- not kolla_externally_managed_cert | bool
- kolla_enable_tls_internal | bool
- name: Fail if internal haproxy certificate is absent
run_once: true
fail:
msg: "Internal haproxy certificate file is not found. It is configured via 'kolla_internal_fqdn_cert'"
when:
- not kolla_externally_managed_cert | bool
- kolla_enable_tls_internal | bool
- not haproxy_internal_cert_file.stat.exists
- not kolla_externally_managed_cert | bool
- name: Checking the kolla_external_vip_interface is present
fail: "msg='Please check the kolla_external_vip_interface property - interface {{ kolla_external_vip_interface }} not found'"

View File

@ -0,0 +1,4 @@
---
fixes:
- |
Fixes HAProxy prechecks when ``kolla_externally_managed_cert`` is used.