-
JWT/API //Permet de générer les clés dans le bon contexte, sans les inclure dans le build de l’image. docker compose exec php sh -c ' apt-get update && apt-get install -y openssl php bin/console lexik:jwt:generate-keypair setfacl -R -m u:www-data:rX -m u:"$(whoami)":rwX config/jwt setfacl -dR -m u:www-data:rX -m u:"$(whoami)":rwX config/jwt '
-
Pour deployer un jeux de datas par défault : php bin/console doctrine:fixtures:load
si necessaire Vérifiez que la structure de la table correspond bien à votre entité php bin/console doctrine:schema:validate
php bin/console make:migration php bin/console doctrine:migrations:migrate
- solution tailwind avec Encore/WebPack encore en test npm install
// compile assets and automatically re-compile when files change npm run watch
//compile assets once npm run dev
//recompile npm run watch
//on deploy, create a production build npm run build
debug Docker : https://forums.docker.com/t/malware-blocked-com-docker-vmnetd-was-not-opened-because-it-contains-malware/145930/39
A Docker-based installer and runtime for the Symfony web framework, with FrankenPHP and Caddy inside!
- If not already done, install Docker Compose (v2.10+)
- Run
docker compose build --no-cache
to build fresh images - Run
docker compose up --pull always -d --wait
to set up and start a fresh Symfony project - Open
https://localhost
in your favorite web browser and accept the auto-generated TLS certificate - Run
docker compose down --remove-orphans
to stop the Docker containers.
- Production, development and CI ready
- Just 1 service by default
- Blazing-fast performance thanks to the worker mode of FrankenPHP (automatically enabled in prod mode)
- Installation of extra Docker Compose services with Symfony Flex
- Automatic HTTPS (in dev and prod)
- HTTP/3 and Early Hints support
- Real-time messaging thanks to a built-in Mercure hub
- Vulcain support
- Native XDebug integration
- Super-readable configuration
Enjoy!
- Options available
- Using Symfony Docker with an existing project
- Support for extra services
- Deploying in production
- Debugging with Xdebug
- TLS Certificates
- Using MySQL instead of PostgreSQL
- Using Alpine Linux instead of Debian
- Using a Makefile
- Updating the template
- Troubleshooting
Symfony Docker is available under the MIT License.
Created by Kévin Dunglas, co-maintained by Maxime Helias and sponsored by Les-Tilleuls.coop.