Files
kolla-ansible/kolla_ansible
Michal Arbet 9c41becc8d Standardize Python interpreter handling
This patch ensures that the system Python interpreter is always used
during the `bootstrap-servers` phase by setting
`ansible_python_interpreter=auto_silent` via `extra_vars`, while the
`octavia-certificates` command now explicitly uses the same Python
interpreter that was used to invoke the `kolla-ansible` CLI, ensuring
compatibility with the local environment.

Summary:
- The `ansible_python_interpreter` is now dynamically defined in
  `group_vars/all.yml`, falling back to the system interpreter if
  no virtualenv is configured.
- CLI commands now detect and respect user-specified
  `ansible_python_interpreter` values via `-e`, and avoid overriding them.
- The `bootstrap-servers` command always uses the system Python interpreter
  by setting `ansible_python_interpreter=auto_silent`, ensuring a clean
  environment for virtualenv creation.
- The `octavia-certificates` command uses the Python interpreter
  that invoked the `kolla-ansible` CLI, ensuring compatibility with
  locally installed packages (e.g. cryptography).

This improves interpreter handling across commands, especially in environments
with custom Python setups or virtual environments.

Depends-On: https://review.opendev.org/c/openstack/ansible-collection-kolla/+/949767

Change-Id: I7dc6cf8eda3b1fd48d2000f18b4670a4ef4ce1b4
2025-05-20 23:01:51 +02:00
..
2024-10-28 08:48:23 +00:00
2024-05-07 10:06:50 +00:00
2024-12-19 08:07:04 +00:00