Skip to content

marcellodesales/php-apache-mysql-4-cakephp-docker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Docker image for php apache for cake-php apps

Since CakePHP apps require MySQL PDO to be installed, I found this to be a very time-consuming. I spent around 5 hours to get this properly configured. CakePHP requires the following:

This image's parent is the latest PHP/Apache image. See more at https://hub.docker.com/_/php/.

Here's a Dockerfile that will work for your CakePHP Application.

FROM marcellodesales/php-apache-cakephp-mysql

ADD . /var/www/html

# In case you need write permissions in a given directory, do it here
RUN mkdir /var/www/html/api/tmp && chmod 777 /var/www/html/api/tmp

CMD ["apache2-foreground"]

After that, just perform a regular build:

docker build -t myCakePhpApp .

Then you simply run your app!

docker run -ti myCakePhpApp

About

Docker image for CakePHP Apps that requires MySQL modules.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published