Fix python path when deploy host is not localhost

When we don't use localhost as deploy host, we need to use
manila_service_setup_host_python_interpreter variable.

This variable give the correct python path (in a venv for example when
we use a utility container as a setup host)

Change-Id: I34070aad44cfcbb59773196b0f74c10225bc9124
This commit is contained in:
Kourosh Vivan 2020-02-25 11:15:34 +01:00
parent 0274e5284b
commit 6170d71caa
2 changed files with 2 additions and 1 deletions

View File

@ -22,6 +22,7 @@ manila_pip_package_state: "latest"
# for the service setup. The host must already have
# clouds.yaml properly configured.
manila_service_setup_host: "{{ openstack_service_setup_host | default('localhost') }}"
manila_service_setup_host_python_interpreter: "{{ openstack_service_setup_host_python_interpreter | default((manila_service_setup_host == 'localhost') | ternary(ansible_playbook_python, ansible_python['executable'])) }}"
# Set installation method.
manila_install_method: "source"

View File

@ -143,7 +143,7 @@
_service_adminuri_insecure: "{{ keystone_service_adminuri_insecure }}"
_service_in_ldap: "{{ manila_service_in_ldap }}"
_service_setup_host: "{{ manila_service_setup_host }}"
_service_setup_host_python_interpreter: "{{ (manila_service_setup_host == 'localhost') | ternary(ansible_playbook_python, ansible_python['executable']) }}"
_service_setup_host_python_interpreter: "{{ manila_service_setup_host_python_interpreter }}"
_service_project_name: "{{ manila_service_project_name }}"
_service_region: "{{ manila_service_region }}"
_service_endpoints: "{{ manila_service_endpoints }}"