loading...

Docker-compose for older PHP Apps

horaciodegiorgi profile image Horacio Degiorgi ・1 min read

Migrate old apps in php sometimes is complicated because is working only for old php version.
I've an old apps working for php 5.2 (some of the libraries are really old) and I need a development environment.
Doing some research I discovered http://devilbox.org/ .
A docker images with a plenty of options and documentation.
My Apps also need postgresql and some php extensions.
In a simple docker-compose recipe I found everything I needed.

I'm running also a pgadmin and a postgresql server with persistent storage.
Docker expose the webserver in the 8100 port and pgadmin in the 8101 port.
All the variables are stored in a .env file in the same directory.

With this simple recipe and docker installed in my laptop with ubuntu I'm ready for a migration to php 7.3 version.

Discussion

pic
Editor guide