See https://bitbucket.org/ua-uits-solarch/docker-phpwebauth for project details
PHP + Apache + mod_auth_cas
This image is built on a basic PHP + Apache image, and adds support for the University of Arizona's CAS implementation, WebAuth.
To build an application on top of this image. Create a new directory containing a new Dockerfile an apache directory and an app directory.
/yourapp apache/ app/ Dockerfile
In the apache directory, put an updated version of the app.conf file from this project. Customize it with your server name, and change the CAS settings if needed.
Put your PHP application files inside of the app/ directory.
Create a Dockerfile that looks something like:
FROM uauitstools/phpwebauth # Copy over the apache conf files COPY apache/ /etc/apache2/conf-enabled/ # Copy over your application COPY app/ /var/www/html/
To build your image:
docker build -t yourproj/yourapp:latest .
To run your application with something like:
docker run -d -name yourapp -p 80:80 yourproj/yourapp
That will start a new container, and map port 80 on the host to port 80 inside the container, where apache is running your application. Change your host port if needed.