This image is based on CentOS 6.6 and currently has Apache2 2.2.15.
This is a simple Apache image, including SSL support. In order to use this image effectively, you'll need to mount:
As per the defaults, Apache will use the bundled "snakeoil" key when serving SSL. Obviously this isn't sufficient or advisable for production, so you'll want to mount your real keys onto /etc/ssl/. If you name them "certs/ssl-cert-snakeoil.pem" and "private/ssl-cert-snakeoil.key", you'll be able to get by with the default config. Otherwise, you'll want to include a revised site definition. If you don't want to use SSL, you can avoid forwarding port 443 when launching the container (see below).
Assuming you have your content at /home/jdoe/mysite/, the below will be sufficient to serve it. Note that many Docker users encourage mounting data from a storage container, rather than directly from the filesyetem.
docker run -p 80:80 -p 443:443 -d sirkkalap/apache-centos and browse to the host's IP address using http or httpsdocker run -p 80:80 -p 443:443 -v /home/jdoe/mysite/:/var/www/ -d sirkkalap/apache-centosdocker -p 80:80 -v /home/jdoe/mysite/:/var/www/ -d sirkkalap/apache-centosdocker -p 8080:80 -p 8443:443 -v /home/jdoe/mysite/:/var/www/ -d sirkkalap/apache-centosContent type
Image
Digest
sha256:0907c64ce…
Size
132.7 MB
Last updated
over 11 years ago
docker pull sirkkalap/apache-centos