docker-rainloop/Dockerfile

56 lines
2.0 KiB
Docker
Raw Normal View History

2016-10-23 08:25:53 +02:00
FROM alpine:edge
2016-09-24 12:46:58 +02:00
MAINTAINER Wonderfall <wonderfall@schrodinger.io>
2016-05-05 09:15:35 +02:00
MAINTAINER Hardware <contact@meshup.net>
2016-09-24 12:46:58 +02:00
ARG GPG_FINGERPRINT="3B79 7ECE 694F 3B7B 70F3 11A4 ED7C 49D9 87DA 4591"
2016-05-13 09:20:21 +02:00
2016-09-24 12:46:58 +02:00
ENV UID=991 GID=991
2016-05-05 09:15:35 +02:00
2016-07-02 09:46:21 +02:00
RUN echo "@commuedge https://nl.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \
2016-05-05 09:15:35 +02:00
&& apk -U add \
2016-05-13 09:20:21 +02:00
gnupg \
2016-05-05 09:15:35 +02:00
nginx \
2016-09-24 12:46:58 +02:00
s6 \
su-exec \
2016-09-02 07:56:18 +02:00
php7-fpm@commuedge \
php7-curl@commuedge \
php7-iconv@commuedge \
php7-xml@commuedge \
php7-dom@commuedge \
php7-openssl@commuedge \
php7-json@commuedge \
php7-zlib@commuedge \
php7-pdo_mysql@commuedge \
php7-pdo_sqlite@commuedge \
php7-sqlite3@commuedge \
2017-01-10 10:33:54 +01:00
php7-ldap@commuedge \
2016-05-13 09:20:21 +02:00
&& cd /tmp \
&& wget -q http://repository.rainloop.net/v2/webmail/rainloop-community-latest.zip \
&& wget -q http://repository.rainloop.net/v2/webmail/rainloop-community-latest.zip.asc \
2016-05-13 09:20:21 +02:00
&& wget -q http://repository.rainloop.net/RainLoop.asc \
&& echo "Verifying authenticity of rainloop-community-latest.zip using GPG..." \
2016-05-13 09:20:21 +02:00
&& gpg --import RainLoop.asc \
&& FINGERPRINT="$(LANG=C gpg --verify rainloop-community-latest.zip.asc rainloop-community-latest.zip 2>&1 \
2016-05-13 09:20:21 +02:00
| sed -n "s#Primary key fingerprint: \(.*\)#\1#p")" \
&& if [ -z "${FINGERPRINT}" ]; then echo "Warning! Invalid GPG signature!" && exit 1; fi \
2016-09-24 12:46:58 +02:00
&& if [ "${FINGERPRINT}" != "${GPG_FINGERPRINT}" ]; then echo "Warning! Wrong GPG fingerprint!" && exit 1; fi \
&& echo "All seems good, now unzipping rainloop-community-latest.zip..." \
&& mkdir /rainloop && unzip -q /tmp/rainloop-community-latest.zip -d /rainloop \
2016-05-13 09:20:21 +02:00
&& find /rainloop -type d -exec chmod 755 {} \; \
&& find /rainloop -type f -exec chmod 644 {} \; \
2016-05-05 09:15:35 +02:00
&& apk del gnupg \
2016-07-02 09:46:21 +02:00
&& rm -rf /tmp/* /var/cache/apk/* /root/.gnupg
2016-05-05 09:15:35 +02:00
COPY nginx.conf /etc/nginx/nginx.conf
2016-05-13 09:20:21 +02:00
COPY php-fpm.conf /etc/php7/php-fpm.conf
2016-09-24 12:46:58 +02:00
COPY s6.d /etc/s6.d
COPY run.sh /usr/local/bin/run.sh
2016-05-05 09:15:35 +02:00
2016-09-24 12:46:58 +02:00
RUN chmod +x /usr/local/bin/run.sh /etc/s6.d/*/* /etc/s6.d/.s6-svscan/*
2016-05-05 09:15:35 +02:00
VOLUME /rainloop/data
2016-09-24 12:46:58 +02:00
EXPOSE 8888
CMD ["run.sh"]