diff options
Diffstat (limited to 'roles')
| -rw-r--r-- | roles/kolla-ansible-test-dashboard/tasks/main.yml | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/roles/kolla-ansible-test-dashboard/tasks/main.yml b/roles/kolla-ansible-test-dashboard/tasks/main.yml new file mode 100644 index 000000000..561867aed --- /dev/null +++ b/roles/kolla-ansible-test-dashboard/tasks/main.yml @@ -0,0 +1,21 @@ +--- +- name: Get contents of clouds.yaml + ansible.builtin.slurp: + src: /etc/kolla/clouds.yaml + register: clouds_yaml + +- name: Query dashboard and check that the returned page looks like a login page + vars: + clouds: "{{ clouds_yaml['content'] | b64decode | from_yaml }}" + url_scheme: "{{ clouds.clouds['kolla-admin'].auth.auth_url | urlsplit('scheme') }}" + url_host: "{{ kolla_external_vip_address | default(kolla_internal_vip_address) }}" + ansible.builtin.uri: + url: "{{ url_scheme + '://' + url_host }}" + ca_path: "{{ clouds.clouds['kolla-admin'].cacert | default(omit) }}" + follow_redirects: "all" + return_content: true + validate_certs: "{{ 'false' if scenario == 'lets-encrypt' else 'true' }}" + register: dashboard_output + until: dashboard_output.content.find('Login') != -1 + retries: 30 + delay: 10 |
