From 74ff77e720ea6b85472d0c884532a4b2ff926da8 Mon Sep 17 00:00:00 2001 From: Ian Wienand Date: Mon, 16 Jan 2023 09:31:04 +1100 Subject: [PATCH] Revert "Override pythonpath in nodepool builder" This reverts commit 515c29572190158428ac172febbf6871cf8977ee. We found the reason why nodepool-builder wasn't starting was that when we had the system-python and upstream-python installed at the same version at the same time, the upstream-python was not built to use relative libraries and hence started using the libpython.so from the system-python. This meant it was looking for libraries installed in the system-python path (dist-packages) not the pip/upstream path (site-packages). This was reported and upstream are currently evaluating a fix for that [1] In the mean time, we merged Ib3dfda3df69e7ab359b96cd1865e47c7e1e8047b which also avoids this problem by not including the "unstable" distro in the image. Since the system-python 3.11 packages were coming from "unstable", this avoids the "same version" of the problem; the upstream-python won't pick up the older version's libpython.so. After this change the image is actually broken with this, because it directs the system-python (now 3.9 since the change) to the 3.11 libraries, which obviously doesn't work. Thus revert this now. [1] https://github.com/docker-library/python/pull/785 Change-Id: I814d5920d8203bcb9f60b9769164c3d2a925f526 --- .../roles/nodepool-builder/templates/docker-compose.yaml.j2 | 3 --- 1 file changed, 3 deletions(-) diff --git a/playbooks/roles/nodepool-builder/templates/docker-compose.yaml.j2 b/playbooks/roles/nodepool-builder/templates/docker-compose.yaml.j2 index ff54a23300..5ac6ca8a40 100644 --- a/playbooks/roles/nodepool-builder/templates/docker-compose.yaml.j2 +++ b/playbooks/roles/nodepool-builder/templates/docker-compose.yaml.j2 @@ -15,9 +15,6 @@ services: - DEBUG=1 - STATSD_HOST=graphite.opendev.org - STATSD_PORT=8125 - # TODO: remove once we fix the arm64 images using dist-packages - # instead of site-packages - - PYTHONPATH=/usr/local/lib/python311.zip:/usr/local/lib/python3.11:/usr/local/lib/python3.11/lib-dynload:/usr/local/lib/python3.11/site-packages volumes: # nodepool config