Public Repository

Last pushed: 2 years ago
Short Description
Apache and PHP made simple.
Full Description

Supported tags and respective Dockerfile links

About this image?

This image come from the official Docker php image

It was builded with the apache version with mod_rewrite and mysqli php extension.

And also with a date.timezone = Europe/Paris

How to use this image

Start a apache server instance with a Dockerfile

Create a Dockerfile in your PHP project

FROM srod/apache-php
COPY src/ /var/www/html/

Where src/ is the directory containing all your php code. Then, run the commands to build and run the Docker image:

$ docker build -t my-php-app .
$ docker run -it --rm --name my-running-app my-php-app

Start a apache server instance with Docker Compose

Create a docker-compose.yml in your PHP project

web:
  image: srod/apache-php
  ports:
    - "8080:80"
  volumes:
    - "./src:/var/www/html"

Where src/ is the directory containing all your php code. Then, run docker-compose:

$ docker-compose up
Docker Pull Command
Owner
srod

Comments (0)