Updated apache dockerfile
This commit is contained in:
parent
5b7c2520ea
commit
58c1b67a91
|
@ -13,14 +13,23 @@ ARG WITH_DATABASE=false
|
||||||
|
|
||||||
ENV WITH_APACHE=${WITH_APACHE}
|
ENV WITH_APACHE=${WITH_APACHE}
|
||||||
ENV WITH_DATABASE=${WITH_DATABASE}
|
ENV WITH_DATABASE=${WITH_DATABASE}
|
||||||
|
ENV APP_ROOT=${SERVER_ROOT}/htdocs
|
||||||
|
|
||||||
ADD scripts/apache-entrypoint.sh /usr/local/bin/entrypoint
|
ADD scripts/apache-entrypoint.sh /usr/local/bin/entrypoint
|
||||||
|
ADD htdocs ${APP_ROOT}
|
||||||
|
|
||||||
# Create directory, and install required php app
|
# Create directory, and install required php app
|
||||||
RUN /bin/sh /tmp/setup.sh; \
|
RUN /bin/sh /tmp/setup.sh; \
|
||||||
/bin/rm -f /tmp/*.sh; \
|
/bin/rm -f /tmp/*.sh; \
|
||||||
rm -vrf /var/cache/apk/*; \
|
rm -vrf /var/cache/apk/*; \
|
||||||
chmod +rx /usr/local/bin/entrypoint ;
|
chmod +rx /usr/local/bin/entrypoint ; \
|
||||||
|
sed -i "s|#version#|${PHP_VERSION}|" /app/htdocs/index.html ; \
|
||||||
|
sed -i "s|#os#|alpine|" /app/htdocs/index.html ; \
|
||||||
|
mkdir -p ${SERVER_ROOT}/logs ${SERVER_ROOT}/run /run/apache2 ; \
|
||||||
|
ln -s /usr/lib/apache2 ${SERVER_ROOT}/modules ; \
|
||||||
|
chmod -R 755 ${SERVER_ROOT}/logs ${SERVER_ROOT/run} ; \
|
||||||
|
chown -R apache:apache ${SERVER_ROOT}/htdocs ${SERVER_ROOT}/logs ${SERVER_ROOT}/run /run/apache2 ; \
|
||||||
|
rm -vrf /var/cache/apk/*
|
||||||
|
|
||||||
FROM scratch
|
FROM scratch
|
||||||
|
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<h1>Welcome to httpd!</h1>
|
<h1>Welcome to httpd!</h1>
|
||||||
<h2>The sindigilive/php:#version#-apache-#flavor#-#os# variant.</h2>
|
<h2>The sindigilive/php:#version#-apache--#os# variant.</h2>
|
||||||
<p>If you see this page, the nginx web server is successfully installed and
|
<p>If you see this page, the nginx web server is successfully installed and
|
||||||
working. Further configuration is required.</p>
|
working. Further configuration is required.</p>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue