From e5731e45addba0139fa80a5b3662eded92857ef9 Mon Sep 17 00:00:00 2001 From: pranavchoudhary-tech Date: Fri, 14 Aug 2026 15:38:55 +0530 Subject: [PATCH] docs: document SELinux bind-mount requirement for devcontainer (#1879) --- getting-started/setup-building.rst | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/getting-started/setup-building.rst b/getting-started/setup-building.rst index 8e35f8a64..381e1db04 100644 --- a/getting-started/setup-building.rst +++ b/getting-started/setup-building.rst @@ -1287,6 +1287,14 @@ in a clone of the CPython repository. docker run -it --rm --volume $PWD:/workspace --workdir /workspace ghcr.io/python/devcontainer:latest +.. note:: + + On SELinux-enabled Linux distributions (such as Fedora or RHEL), Docker requires + the ``:z`` or ``:Z`` flag on the volume mount (e.g. ``$PWD:/workspace:Z``) + or passing ``--security-opt label=disable`` to avoid permission errors inside + the container. + + Note that the container has read/write access to the working directory. You may want to use a separate clone of CPython, or run ``make clean`` to remove caches and build output generated for your host OS.