The source code of the web application/API used for MarketReminder mobile application.
Once you've installed Docker, time to build the project.
This project use Docker environment files in order to allow the configuration according to your needs, this way, you NEED to define a .env file in order to launch the build.
In order to perform better, Docker can block your dependencies installation and return an error or never change your php configuration, we recommend to delete all your images/containers before building the project
docker stop $(docker ps -a -q)
docker rm $(docker ps -a -q)
docker rmi $(docker images -a -q) -f
Note that this command can take several minutes before ending
Once this is done, let's build the project.
cp .env.dist .env
Update the information linked to Docker then use Docker-Compose :
make start
Then you must use Composer in order to launch the application :
docker exec -it project_php-fpm sh
# Use Composer inside the container for better performances.
composer install
composer clear-cache
composer dump-autoload --optimize --classmap-authoritative
# Configure BDD
./bin/console d:s:c # for classic users
# Fixtures
./bin/console d:f:l -n
Once this is done, access the project via your browser :
http://localhost:port/
For the production approach, you must update the .env file and change the APP_ENV and APP_DEBUG keys.
http://localhost:port/
If you need to perform some tasks:
make // See the PHP commands
Once in the container:
# Example for clearing the cache
make cache-clear
Please note that you MUST open a second terminal in order to keep git ou other commands line outside of Docker
cd core
php bin/console s:r || ./bin/console s:r || make serve
Then access the project via your browser:
http://localhost:8000
The commands listed before stay available and needed for this approach
This project use PHPUnit, Behat and Blackfire in order to test and validate his internal logic, here the listing of available commands for testing purpose:
make phpunit FOLDER=desiredfolder
make phpunit-blackfire FOLDER=desiredfolder
make behat
See Contributing