-
Notifications
You must be signed in to change notification settings - Fork 128
/
Dockerfile
53 lines (48 loc) · 1.54 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
FROM alpine:3.7
LABEL description "Next-generation forum software that makes online discussion fun" \
maintainer="Hardware <hardware@mondedie.fr>, Magicalex <magicalex@mondedie.fr>"
ARG VERSION=v0.1.0-beta.7
ENV GID=991 \
UID=991 \
UPLOAD_MAX_SIZE=50M \
PHP_MEMORY_LIMIT=128M \
OPCACHE_MEMORY_LIMIT=128
RUN echo "@community https://nl.alpinelinux.org/alpine/v3.7/community" >> /etc/apk/repositories \
&& apk add -U \
nginx \
s6 \
su-exec \
curl \
php7@community \
php7-fileinfo@community \
php7-phar@community \
php7-fpm@community \
php7-curl@community \
php7-mbstring@community \
php7-openssl@community \
php7-json@community \
php7-pdo@community \
php7-pdo_mysql@community \
php7-mysqlnd@community \
php7-zlib@community \
php7-gd@community \
php7-dom@community \
php7-ctype@community \
php7-session@community \
php7-opcache@community \
php7-xmlwriter@community \
php7-tokenizer@community \
&& cd /tmp \
&& curl -s http://getcomposer.org/installer | php \
&& mv /tmp/composer.phar /usr/bin/composer \
&& chmod +x /usr/bin/composer \
&& mkdir -p /flarum/app \
&& chown -R $UID:$GID /flarum \
&& COMPOSER_CACHE_DIR="/tmp" su-exec $UID:$GID composer create-project flarum/flarum /flarum/app $VERSION --stability=beta \
&& composer clear-cache \
&& rm -rf /flarum/.composer /var/cache/apk/*
COPY rootfs /
RUN chmod +x /usr/local/bin/* /services/*/run /services/.s6-svscan/*
VOLUME /flarum/app/assets /flarum/app/extensions
EXPOSE 8888
CMD ["run.sh"]