My project involves using Symfony and Docker with Dev Containers.
It helps me create a customized development environment for my Symfony application.
With Docker, I can package and deploy my application consistently.
Dev Containers simplifies dependency management and streamlines the development process. Together, Symfony, Docker, and Dev Containers enhance my workflow and ensure seamless application deployment.
If Docker is not already installed, follow these links to install it:
For Windows: Please refer to the instructions specific to Windows.
For Linux: Please refer to the instructions specific to Linux.
For Macos: Please refer to the instructions specific to Macos.
Clone the repository of your choice and using the following command: exemple select branch Symfony-6.3 or Symfony-6.3-OD (OD is Only Docker is a repo without symfony generate)
git clone "url"
Download the Dev Containers extension by Microsoft and the Docker extension if you haven't already.
Press F1
in VSCode and select "Dev Containers: Open Folder in Dev Container" from the dropdown menu.
Let the magic happen as the dev container is set up for you.
a make new
command will be available for you to use.
Simply run the command make install
to proceed.
Please note that these instructions assume a basic familiarity with using Git, Docker, and Visual Studio Code.
To use the Makefile in CMD, navigate to its directory and run "make [target]". Replace "[target]" with the desired target name, like "install" or "run".
Displays usage instructions and a list of available targets with their descriptions.
Creates a new Symfony project using the symfony command.
Installs yarn using npm.
Requires the symfony/webpack-encore-bundle package using composer.
Prompts the user to cut and paste the symfony project folder to the desired location.
Cleans up the temporary symfony folder.
Requires the symfony/orm-pack and symfony/maker-bundle packages using composer. Invokes the yarn target.
Requires the symfony/webpack-encore-bundle package using composer.
Installs JavaScript dependencies using yarn install.
Starts the Symfony development server using the symfony command.
Starts both the Symfony development server and the webpack Encore dev server concurrently using the symfony and yarn commands respectively.
If you want access to phpmyadmin go to http://localhost:8090/ for connection by default is Server : db User : mariadb Password : mariadb
If you prefer to use the command prompt with MariaDB, it would be:
mysql -h 127.0.0.1 -P 3306 --protocol=tcp -u root -p
Password: mariadb