PHP 5.4, despite being a minor update, introduced a series breaking changes in PHP language. There are many legacy applications in the web that won't work with PHP older than 5.3. This docker image aims to fix the problem, providing PHP 5.3 environment for legacy applications.
Image expects application's document root to be in /web
.
Create Dockerfile
in root of webapplication, with one line:
FROM koder/apache-php-5.3
Build and run with:
docker build -t <project-name> .
docker run -it --rm -p 8080:80 <project-name>
This image installs dependencies automaticly, just place relevant file in root of your legacy application.
bower.json
will runbower install
package.json
will runnpm install
composer.json
will install composer and runcomposer.phar install
If you place php.ini
file in root of your application, it will be used as conf.d
.
If possible, you should use smtp
to send e-mails from your application. If your legacy app
relies on PHP mail()
function and is impractical to rewrite, this image comes pre-installed
with ssmtp to push your emails to specified external smtp
service. To use ssmtp
simply place ssmtp.conf
file in root of your application. Minimal
example:
[email protected]
mailhub=smtp.yourmail.com
hostname=yourserver.example.com
FromLineOverride=YES
[email protected]
AuthPass=password