FROM alpine:3.11 AS builder ENV VERSION=1.4.2 ENV SHA256_SUM=c83a746c3ab561ab51df5729627d33bba3520c5d59ee03762739b4e8ad9b0f69 RUN wget https://github.com/roundcube/roundcubemail/releases/download/$VERSION/roundcubemail-$VERSION-complete.tar.gz RUN echo "$SHA256_SUM roundcubemail-$VERSION-complete.tar.gz" | sha256sum -c - || exit 1 RUN mkdir -p /var/lib/roundcube RUN tar xzf roundcubemail-$VERSION-complete.tar.gz -C /var/lib/roundcube --strip 1 FROM thallian/php7-fpm:latest COPY --from=builder /var/lib/roundcube /var/lib/roundcube RUN apk add --no-cache \ openssl \ tar \ nginx \ postgresql-client \ aspell \ ca-certificates \ php7 \ php7-imap \ php7-dom \ php7-json \ php7-xml \ php7-session \ php7-pdo \ php7-pdo_pgsql \ php7-sockets \ php7-exif \ php7-iconv \ php7-openssl \ php7-mbstring \ php7-sockets \ php7-mcrypt \ php7-zip \ php7-ldap \ php7-pspell \ php7-apcu \ php7-gd \ php7-ctype \ php7-xmlwriter \ php7-tokenizer \ php7-curl \ php7-simplexml \ composer WORKDIR /var/lib/roundcube RUN composer require --update-no-dev roundcube/carddav WORKDIR / RUN chown -R nginx:nginx /var/lib/roundcube RUN mkdir /run/nginx ADD /rootfs / EXPOSE 80 ENV FPMUSER nginx ENV FPMGROUP nginx