Add comprehensive documentation and testing for Podman mount relabel issue
This PR provides a complete solution package for the Podman mount relabel issue where Dev Container CLI generates invalid mount syntax that fails on systems without SELinux.
Problem
The Dev Container CLI generates Dockerfiles with RUN --mount=type=bind,...,z syntax for features installation. The z flag is invalid for --mount in Podman (only valid for --volume), causing this error on systems without SELinux:
bind mounts cannot have any filesystem-specific options applied
Solution Package
📚 Documentation
- Technical Fix Guide - Root cause analysis and solution approaches
- User Workaround Guide - Immediate workarounds while awaiting permanent fix
🔧 Tools & Scripts
- Compatibility Check - Assess if your system is affected
- Test Script - Validate different mount syntax solutions
- Reproduction Case - Minimal config to reproduce the issue
💡 Solution Options Documented
-
relabel=shared - Correct
--mountequivalent of thezflag - --security-opt=label=disable - Broader compatibility approach
Usage
Check if you're affected:
./docs/check-podman-compatibility.sh
Apply immediate workaround:
# Follow steps in docs/podman-mount-workaround.md
Test the fix approaches:
./docs/test-podman-mount-fix.sh
Impact
- Immediate relief for affected users via documented workarounds
- Technical foundation for implementing the permanent fix in devcontainers/cli
- Testing framework to validate solution approaches
- Risk assessment to help users understand their exposure
This addresses the issue comprehensively while the permanent fix is coordinated with the upstream devcontainers/cli repository.
Fixes #10585.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.