Public Repository

Last pushed: a year ago
Short Description
Base CentOS image for web apps
Full Description

FROM centos:7

RUN rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
RUN rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm

RUN yum update -y

RUN yum install -y httpd

RUN yum install -y yum php70w php70w-bcmath php70w-cli php70w-common php70w-mbstring php70w-mysqlnd php70w-pdo php70w-gd php70w-pecl-xdebug php70w-mcrypt

RUN yum clean all

ADD docker-resources/php.ini-development /etc/php.ini

RUN sed -i 's!/var/www/html!/var/www/public!g' /etc/httpd/conf/httpd.conf
RUN sed -i '/<Directory "\/var\/www\/public">/,/<\/Directory>/ s/AllowOverride None/AllowOverride all/' /etc/httpd/conf/httpd.conf
RUN sed -i.orig 's/#ServerName/ServerName/' /etc/httpd/conf/httpd.conf

RUN [ -d /var/log/httpd ] || mkdir /var/log/httpd
RUN [ -d /var/run/httpd ] || mkdir /var/run/httpd
RUN [ -d /var/lock/httpd ] || mkdir /var/lock/httpd

ENV APACHE_RUN_USER apache
ENV APACHE_RUN_GROUP apache
ENV APACHE_LOG_DIR /var/log/httpd
ENV APACHE_LOCK_DIR /var/lock/httpd
ENV APACHE_RUN_DIR /var/run/httpd
ENV APACHE_PID_FILE /var/run/httpd/httpd.pid

WORKDIR /var/www

VOLUME /var/www

EXPOSE 80

CMD ["/usr/sbin/httpd", "-D", "FOREGROUND"]

Docker Pull Command
Owner
xpwales

Comments (0)