-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Description
Description
Proposal
Add a .devcontainer/
folder to provide optional support for GitHub Codespaces and Visual Studio Code's DevContainer feature.
This would allow new contributors to get a ready-to-use Symfony development environment instantly, without manually configuring PHP, required extensions (like ext-xsl), or Composer.
What's included
- A minimal Dockerfile based on
php:8.3-alpine
- Composer preinstalled globally
- Required PHP extensions like
xsl
(used in core) - A non-root user (
devuser
) for good container practices - Workspace mapped to
/workspaces/symfony
- Recommended VS Code extensions (PHP, Xdebug, etc.)
Why
Symfony has a large and growing contributor base, but setting up a full local environment remains a barrier, especially for new contributors or those exploring the codebase.
Providing an optional, zero-config, fully reproducible container environment helps:
- Lower the entry barrier for contributions
- Encourage contributions via GitHub Codespaces
- Ensure environment consistency during PR testing/debugging
Impact
This is completely optional. It has:
- No impact on the Symfony runtime
- No change to the test pipeline
- No dependency on external services
It only adds a .devcontainer/
folder at the root, which is ignored by Symfony’s autoloading, tests, and builds.
Preview
I’ve implemented a working version in a dedicated branch here (not submitted as a PR yet, pending approval):
🔗 https://github.com/mathieucorne/symfony/tree/feature/devcontainer-support
📁 https://github.com/mathieucorne/symfony/tree/feature/devcontainer-support/.devcontainer
Let me know if this is something you'd be interested in — I’ll gladly open a PR if approved.