diff --git a/ansible/configs/ocp4-disconnected-osp-lab/files/clouds.yaml.j2 b/ansible/configs/ocp4-disconnected-osp-lab/files/clouds.yaml.j2 index 8aaa732cd18..2fe7febb5fa 100644 --- a/ansible/configs/ocp4-disconnected-osp-lab/files/clouds.yaml.j2 +++ b/ansible/configs/ocp4-disconnected-osp-lab/files/clouds.yaml.j2 @@ -2,11 +2,11 @@ clouds: {{ osp_project_name }}: auth: auth_url: "{{ osp_auth_url }}" - username: "{{ guid }}-user" + username: "{{ osp_auth_username_member }}" + password: "{{ osp_auth_password_member }}" project_name: "{{ osp_project_name }}" - project_id: "{{ hostvars['localhost']['osp_project_info'][0].id }}" + project_id: "{{ hostvars['localhost']['osp_project_info'][0].id | default(osp_project_id) }}" user_domain_name: "Default" - password: "{{ hostvars['localhost']['heat_user_password'] }}" region_name: "regionOne" interface: "public" - identity_api_version: 3 \ No newline at end of file + identity_api_version: 3 diff --git a/ansible/roles/host-ocp4-provisioner/templates/clouds.yaml.j2 b/ansible/roles/host-ocp4-provisioner/templates/clouds.yaml.j2 index ff7a1ab0bcf..3324d4542a3 100644 --- a/ansible/roles/host-ocp4-provisioner/templates/clouds.yaml.j2 +++ b/ansible/roles/host-ocp4-provisioner/templates/clouds.yaml.j2 @@ -2,13 +2,8 @@ clouds: {{ osp_cloud_name }}: auth: auth_url: "{{ osp_auth_url }}" -{% if osp_project_create | bool %} - username: "{{ guid }}-user" - password: "{{ hostvars['localhost']['heat_user_password'] }}" -{% else %} - username: "{{ osp_auth_username }}" - password: "{{ osp_auth_password }}" -{% endif %} + username: "{{ osp_auth_username_member }}" + password: "{{ osp_auth_password_member }}" project_name: "{{ osp_project_name }}" project_id: "{{ hostvars['localhost']['osp_project_info'][0].id | default(osp_project_id) }}" user_domain_name: "{{ hostvars['localhost']['osp_auth_user_domain'] | d('Default') }}"