As of today, the web-server Dockerfile will not build with the following error:
=> ERROR [prankweb-web-server 8/8] RUN pip3 install -r requirements.txt 1.3s
------
> [prankweb-web-server 8/8] RUN pip3 install -r requirements.txt:
#0 1.030 error: externally-managed-environment
#0 1.030
#0 1.030 × This environment is externally managed
#0 1.030 ╰─> To install Python packages system-wide, try apt install
#0 1.030 python3-xyz, where xyz is the package you are trying to
#0 1.030 install.
#0 1.030
#0 1.030 If you wish to install a non-Debian-packaged Python package,
#0 1.030 create a virtual environment using python3 -m venv path/to/venv.
#0 1.030 Then use path/to/venv/bin/python and path/to/venv/bin/pip. Make
#0 1.030 sure you have python3-full installed.
#0 1.030
#0 1.030 If you wish to install a non-Debian packaged Python application,
#0 1.030 it may be easiest to use pipx install xyz, which will manage a
#0 1.030 virtual environment for you. Make sure you have pipx installed.
#0 1.030
#0 1.030 See /usr/share/doc/python3.11/README.venv for more information.
#0 1.030
#0 1.030 note: If you believe this is a mistake, please contact your Python installation or OS distribution provider. You can override this, at the risk of breaking your Python installation or OS, by passing --break-system-packages.
#0 1.030 hint: See PEP 668 for the detailed specification.
------
failed to solve: executor failed running [/bin/sh -c pip3 install -r requirements.txt]: exit code: 1
Current workaround is to create a virtual environment in the Dockerfile and run the commands inside the venv (I can provide a hotfix) or by providing the --break-system-packages flag, but we should discuss this more.
As of today, the web-server Dockerfile will not build with the following error:
As mentioned in this issue https://github.com/python/cpython/issues/102134, it seems like it is a Debian problem.
Current workaround is to create a virtual environment in the Dockerfile and run the commands inside the venv (I can provide a hotfix) or by providing the
--break-system-packages
flag, but we should discuss this more.