2016-07-14 04:12:58 -04:00
|
|
|
FROM xataz/alpine:3.4
|
|
|
|
MAINTAINER xataz <https://github.com/xataz>
|
|
|
|
MAINTAINER hardware <https://github.com/hardware>
|
|
|
|
|
2016-07-17 05:35:13 -04:00
|
|
|
ARG VERSION=v0.1.0-beta.5
|
|
|
|
|
2016-07-18 01:34:39 -04:00
|
|
|
ENV GID=991 UID=991
|
2016-07-14 04:12:58 -04:00
|
|
|
|
2016-09-02 01:57:43 -04:00
|
|
|
RUN echo "@commuedge https://nl.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \
|
2016-07-18 01:34:39 -04:00
|
|
|
&& apk --no-cache add nginx \
|
2016-07-16 06:07:10 -04:00
|
|
|
curl \
|
|
|
|
supervisor \
|
2016-07-17 05:35:13 -04:00
|
|
|
mariadb-client \
|
2016-09-02 01:57:43 -04:00
|
|
|
php7-phar@commuedge \
|
|
|
|
php7-fpm@commuedge \
|
|
|
|
php7-curl@commuedge \
|
|
|
|
php7-mbstring@commuedge \
|
|
|
|
php7-openssl@commuedge \
|
|
|
|
php7-json@commuedge \
|
|
|
|
php7-pdo_mysql@commuedge \
|
|
|
|
php7-gd@commuedge \
|
|
|
|
php7-dom@commuedge \
|
|
|
|
php7-ctype@commuedge \
|
|
|
|
php7-session@commuedge \
|
|
|
|
php7-opcache@commuedge \
|
2016-07-14 04:12:58 -04:00
|
|
|
&& cd /tmp \
|
|
|
|
&& ln -s /usr/bin/php7 /usr/bin/php \
|
2016-07-18 01:34:39 -04:00
|
|
|
&& curl -s http://getcomposer.org/installer | php \
|
|
|
|
&& mv /tmp/composer.phar /usr/bin/composer \
|
|
|
|
&& chmod +x /usr/bin/composer \
|
2016-07-17 09:55:22 -04:00
|
|
|
&& mkdir -p /flarum/app \
|
2016-07-14 04:12:58 -04:00
|
|
|
&& addgroup -g ${GID} flarum && adduser -h /flarum -s /bin/sh -D -G flarum -u ${UID} flarum \
|
2016-07-17 09:55:22 -04:00
|
|
|
&& chown -R flarum:flarum /flarum \
|
2016-07-18 01:34:39 -04:00
|
|
|
&& su-exec flarum:flarum composer create-project flarum/flarum /flarum/app $VERSION --stability=beta \
|
|
|
|
&& composer clear-cache \
|
|
|
|
&& rm -rf /flarum/.composer /var/cache/apk/*
|
2016-07-14 04:12:58 -04:00
|
|
|
|
2016-07-17 09:55:22 -04:00
|
|
|
COPY config.sql /flarum/app/config.sql
|
2016-07-14 04:12:58 -04:00
|
|
|
COPY nginx.conf /etc/nginx/nginx.conf
|
|
|
|
COPY php-fpm.conf /etc/php7/php-fpm.conf
|
2016-07-18 01:55:59 -04:00
|
|
|
COPY opcache.ini /etc/php7/conf.d/00_opcache.ini
|
2016-07-14 04:12:58 -04:00
|
|
|
COPY supervisord.conf /etc/supervisor/supervisord.conf
|
2016-07-17 05:35:13 -04:00
|
|
|
COPY startup /usr/local/bin/startup
|
2016-07-23 11:46:59 -04:00
|
|
|
COPY composer /usr/local/bin/composeur
|
2016-07-18 01:34:39 -04:00
|
|
|
|
2016-07-23 11:46:59 -04:00
|
|
|
RUN chmod +x /usr/local/bin/*
|
2016-07-14 04:12:58 -04:00
|
|
|
|
2016-07-23 02:44:00 -04:00
|
|
|
VOLUME /flarum/app/assets
|
2016-07-14 04:12:58 -04:00
|
|
|
EXPOSE 8080
|
2016-07-17 05:35:13 -04:00
|
|
|
CMD ["/usr/bin/tini","--","startup"]
|