From 6b6d5ba3a4523235ae0301fdc4c50a0c895fcfff Mon Sep 17 00:00:00 2001 From: Brett Meehan Date: Mon, 6 Jan 2020 15:55:29 +1100 Subject: [PATCH] ITOPSENG-359 fixing context_path for crowd while im at it --- roles/crowd_config/tasks/main.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/roles/crowd_config/tasks/main.yml b/roles/crowd_config/tasks/main.yml index b5b987c..1827975 100644 --- a/roles/crowd_config/tasks/main.yml +++ b/roles/crowd_config/tasks/main.yml @@ -91,3 +91,19 @@ owner: "{{ atl_product_user }}" group: "{{ atl_product_user }}" changed_when: false # For Molecule idempotence check + +- name: Assert baseurl to same as atl_proxy_name + postgresql_query: + login_host: "{{ atl_db_host }}" + login_user: "{{ atl_jdbc_user }}" + login_password: "{{ atl_jdbc_password }}" + db: "{{ atl_jdbc_db_name }}" + query: > + update cwd_property set property_value=%s + where property_name = 'base.url' + positional_args: + - "{{ atl_tomcat_scheme }}://{{ atl_proxy_name }}{{ atl_tomcat_contextpath }}/crowd" + when: + - atl_proxy_name is defined + - atl_tomcat_scheme is defined + ignore_errors: yes # For Molecule as it has no db test framework included