Install python packages into the venv fails for the heat_api_container due to missing "git" command on the openstack-ansible setup-openstack.yml playbook.
TASK [python_venv_build : Install python packages into the venv] ****************************************************************************************
FAILED - RETRYING: [infra1_heat_api_container-9e3029c4]: Install python packages into the venv (5 retries left).
FAILED - RETRYING: [infra1_heat_api_container-9e3029c4]: Install python packages into the venv (4 retries left).
FAILED - RETRYING: [infra1_heat_api_container-9e3029c4]: Install python packages into the venv (3 retries left).
FAILED - RETRYING: [infra1_heat_api_container-9e3029c4]: Install python packages into the venv (2 retries left).
FAILED - RETRYING: [infra1_heat_api_container-9e3029c4]: Install python packages into the venv (1 retries left).
fatal: [infra1_heat_api_container-9e3029c4]: FAILED! => {"attempts": 5, "changed": false, "cmd": ["/openstack/venvs/heat-25.1.0.dev99/bin/pip", "install", "-U", "--constraint", "/openstack/venvs/heat-25.1.0.dev99/global-constraints.txt", "--constraint", "/openstack/venvs/heat-25.1.0.dev99/constraints.txt", "--pre", "--log", "/var/log/python_venv_build.log", "cryptography", "git+https://opendev.org/openstack/heat@c37ea72a6b2c424136ed2ee2cd378928021da78e#egg=openstack-heat", "keystonemiddleware", "osprofiler", "pymemcache", "PyMySQL", "python-glanceclient", "python-heatclient", "python-keystoneclient", "python-memcached", "python-neutronclient", "python-novaclient", "python-openstackclient", "python-swiftclient", "python-troveclient", "systemd-python"], "msg": "stdout: Collecting openstack-heat\n Cloning https://opendev.org/openstack/heat (to revision c37ea72a6b2c424136ed2ee2cd378928021da78e) to ./pip-install-ijoya4u8/openstack-heat_1e51b283ec544c7c83fe6b3f2b6517fa\n\n[notice] A new release of pip available: 22.1.2 -> 22.3\n[notice] To update, run: python3 -m pip install --upgrade pip\n\n:stderr: ERROR: Error [Errno 2] No such file or directory: 'git' while executing command git version\nERROR: Cannot find command 'git' - do you have 'git' installed and in your PATH?\n"}
+++++++++++++++++
I was able to overcome this by manually attaching to the heat container and installing git from within it.
root@infra1:/opt/openstack-ansible/playbooks# lxc-attach infra1_heat_api_container-9e3029c4
root@infra1-heat-api-container-9e3029c4:/# git
bash: git: command not found
root@infra1-heat-api-container-9e3029c4:/# apt install git
Re-run the playbook.
Environment:
-Clean minimal installation of Debian 11 on deployment, infrastructure, and compute hosts.
-Heat container is being installed on the infrastructure host.
Fix proposed to branch: master /review. opendev. org/c/openstack /openstack- ansible- os_heat/ +/864526
Review: https:/