The project has been developed and optimized for use with Docker.
- PHP 8.1 (with PDO & Intl extensions)
- MySQL 8.0
- Composer 2.3
- Node.js 18.4
-
Clone or download the source code and extract it.
-
In the root folder of the project, run the following commands to install and build the necessary dependencies:
-
npm ci
&npm run build
- Allows to install and build Node.js dependencies
-
composer install
- Allows to install PHP dependencies
-
-
Import the database structure contained in the
blog.sql
file. -
Launch the local internal PHP server:
php -S localhost:8000 -t public/
-
Access the blog at: http://localhost:8000
If you need to modify configuration items such as database access or mail gateway, just edit the config.php
file at the root of the project.
If this file has not been created, you can use the config.php.dist
template by duplicating it and renaming it config.php
.
You can load fake datasets (users and blog posts) by running the command:
php bin/console fixtures:load
-
docker run -it --rm -v ${PWD}:/app composer install
- Install php dependencies
-
docker run -it --rm -v ${PWD}:/app -w /app node npm ci
- Install node dependencies
-
docker run -it --rm -v ${PWD}:/app -w /app node npm run build
- Build node dependencies
-
docker-compose up -d --build
- Start the containers
- Access the blog at: http://localhost
-
docker-compose exec app php bin/console fixtures:load
- Add fake default datasets