Sign inSign up

krosh961/apache-php7-docker

By krosh961

•Updated over 8 years ago

This is a micro docker container based on Alpine 3.7, Apache 2.4 and php7

Image
1

258

krosh961/apache-php7-docker repository overview

⁠Alpine microcontainer with apache and php7

This is a micro docker container based on Alpine 3.7, Apache 2.4 and php7

⁠Examples

This images are build on nimmis/alpine-micro which are a modified version of Alpine with a working init process, and a working cron, logrotate and syslog. Services are started with runit daemon, for more information about that see krosh961/alpine3.7-docker⁠

⁠starting the container as a daemon
docker run -d --name apache-php7 krosh961/apache-php7-docker

This will start the container with apache process runnung, access the container with

docker exec -ti apache-php7 /bin/sh
⁠Static web folder

The images exposes a volume at /web. The structure below /web is

DirectoryFunction
htmlweb root
cgi-bincgi bin folder
configconfig directory
logslog directory

To use this start the container with

docker run -d --name apache-php7 -v /path/to/web:/web krosh961/apache-php7-docker

if the folders are missing they will be created

⁠Accessing apache from outside the container

To access the webserver from external you use the -P command where the syntax is

-P <external port on host>:<local port in container>

so to access the apache server on port 8080 you should use the command

docker run -d --name apache-php7 -p 8080:80  krosh961/apache-php7-docker

=======

Tag summary

Content type

Image

Digest

Size

39.8 MB

Last updated

over 8 years ago

docker pull krosh961/apache-php7-docker