Validation should use the public endpoint

It was erroneous to use the admin endpoint as it's not accessible from
the undercloud anymore.

Related: https://bugzilla.redhat.com/show_bug.cgi?id=1921114

Conflict:
  roles/overcloud_service_status/resources/scripts/http_server.py

NOTE(dvd): Train supports python2 so the url formatting is a bit
different.

Change-Id: I2cf2280e4a4599f60c0cce550358f9cf3a20f802
(cherry picked from commit 7e5f0acbe2)
(cherry picked from commit d7b344b5d1)
(cherry picked from commit 55dad79081)
This commit is contained in:
David Vallee Delisle 2021-04-27 15:11:16 -04:00
parent 7bb61c00c7
commit 07ffeb147a
2 changed files with 8 additions and 8 deletions

View File

@ -125,15 +125,15 @@ class S(BaseHTTPRequestHandler):
"endpoints": [ "endpoints": [
{ {
"url": cinder_url, "url": cinder_url,
"interface": "admin", "interface": "public",
}, },
{ {
"url": cinder_url, "url": cinder_url,
"interface": "admin", "interface": "public",
}, },
{ {
"url": cinder_url, "url": cinder_url,
"interface": "admin", "interface": "public",
}, },
], ],
"name": "cinderv3", "name": "cinderv3",
@ -142,15 +142,15 @@ class S(BaseHTTPRequestHandler):
"endpoints": [ "endpoints": [
{ {
"url": nova_url, "url": nova_url,
"interface": "admin", "interface": "public",
}, },
{ {
"url": nova_url, "url": nova_url,
"interface": "admin", "interface": "public",
}, },
{ {
"url": nova_url, "url": nova_url,
"interface": "admin", "interface": "public",
}, },
], ],
"name": "nova", "name": "nova",

View File

@ -16,14 +16,14 @@
- name: Extracting the endpoint url - name: Extracting the endpoint url
set_fact: set_fact:
endpoint: "{{ catalog.endpoints|selectattr('interface', 'eq', 'admin')|first }}" endpoint: "{{ catalog.endpoints|selectattr('interface', 'eq', 'public')|first }}"
loop: "{{ auth_token.json.token.catalog }}" loop: "{{ auth_token.json.token.catalog }}"
loop_control: loop_control:
loop_var: catalog loop_var: catalog
when: catalog.name == os_service when: catalog.name == os_service
- fail: - fail:
msg: "No endpoint found for {{ os_service }} interface admin in catalog" msg: "No endpoint found for {{ os_service }} interface public in catalog"
when: endpoint is not defined when: endpoint is not defined
- name: Get services - name: Get services