-
Copy Dockerfile and docker-compose.yml files to your project root directory.
-
Make sure you update the database in config/app.php and MYSQL_DATABASE in docker-compose.yml.
-
Build the image of the container
docker-compose build
-
Start the service
docker-compose up
-
Stop the service
docker-compose down
-
Install the composer
docker-compose run cakephp composer install --no-interaction
-
Migration
docker-compose run cakephp bin/cake migrations migrate
-
Stop service with volume
docker-compose down -v
-
Copy the project folder
-
Update the base image in docker file.
-
Follow the "Setup CakePHP using docker" steps.