rearrange dockerfile
This commit is contained in:
parent
63f417158f
commit
2216531bfe
31
Dockerfile
31
Dockerfile
|
@ -1,36 +1,29 @@
|
|||
FROM nephatrine/base-php7:latest
|
||||
LABEL maintainer="Daniel Wolf <nephatrine@gmail.com>"
|
||||
|
||||
RUN echo "====== RUNTIME CONFIGURATION ======" \
|
||||
RUN echo "====== INSTALL PACKAGES ======" \
|
||||
&& apk --update upgrade \
|
||||
&& apk add \
|
||||
ffmpeg \
|
||||
imagemagick \
|
||||
zip \
|
||||
&& mkdir -p /mnt/media \
|
||||
&& apk add ffmpeg imagemagick zip \
|
||||
\
|
||||
&& echo "====== BUILD CONFIGURATION ======" \
|
||||
&& apk add --virtual .build-h5ai \
|
||||
nodejs-npm \
|
||||
&& echo "====== INSTALL BUILD TOOLS ======" \
|
||||
&& apk add --virtual .build-h5ai nodejs-npm \
|
||||
\
|
||||
&& echo "====== INSTALL H5AI ======" \
|
||||
&& echo "====== COMPILE H5AI ======" \
|
||||
&& cd /usr/src \
|
||||
&& git clone https://github.com/lrsjng/h5ai.git && cd h5ai \
|
||||
&& npm install && npm run build \
|
||||
&& git clone https://github.com/lrsjng/h5ai.git \
|
||||
&& cd h5ai \
|
||||
&& npm install \
|
||||
&& npm run build \
|
||||
&& unzip build/*.zip -d /var/www/html/ \
|
||||
\
|
||||
&& echo "====== CONFIGURE NGINX ======" \
|
||||
&& echo "====== CONFIGURE SYSTEM ======" \
|
||||
&& mkdir -p /mnt/media \
|
||||
&& sed -i 's~index.html~index.html /_h5ai/public/index.php~g' /etc/nginx/nginx.conf \
|
||||
\
|
||||
&& echo "====== CONFIGURE PHP-FPM ======" \
|
||||
&& sed -i 's~/mnt/config/www/~/mnt/config/www/:/mnt/media/~g' /etc/php/php-fpm.d/www.conf \
|
||||
\
|
||||
&& echo "====== CLEANUP ======" \
|
||||
&& cd /usr/src \
|
||||
&& apk del --purge .build-h5ai \
|
||||
&& rm -rf \
|
||||
/tmp/* \
|
||||
/usr/src/* \
|
||||
/var/cache/apk/*
|
||||
&& rm -rf /tmp/* /usr/src/* /var/cache/apk/*
|
||||
|
||||
COPY override /
|
Loading…
Reference in New Issue