update to alpine:latest, php8 and rainloop 1.17
This commit is contained in:
		
							
								
								
									
										63
									
								
								Dockerfile
									
									
									
									
									
								
							
							
						
						
									
										63
									
								
								Dockerfile
									
									
									
									
									
								
							| @@ -1,14 +1,14 @@ | |||||||
| FROM alpine:3.10 | FROM alpine:latest | ||||||
|  |  | ||||||
| LABEL description "Rainloop is a simple, modern & fast web-based client" \ | LABEL description "Rainloop is a simple, modern & fast web-based client" \ | ||||||
|       maintainer="Hardware <contact@meshup.net>" |       maintainer="Hardware <contact@meshup.net>" | ||||||
|  |  | ||||||
| ARG GPG_FINGERPRINT="3B79 7ECE 694F 3B7B 70F3  11A4 ED7C 49D9 87DA 4591" | ARG GPG_FINGERPRINT="3B79 7ECE 694F 3B7B 70F3  11A4 ED7C 49D9 87DA 4591" | ||||||
|  | ARG RAINLOOP_VERSION=1.17.0 | ||||||
|  |  | ||||||
| ENV UID=991 GID=991 UPLOAD_MAX_SIZE=25M LOG_TO_STDOUT=false MEMORY_LIMIT=128M | ENV UID=991 GID=991 UPLOAD_MAX_SIZE=25M LOG_TO_STDOUT=false MEMORY_LIMIT=128M | ||||||
|  |  | ||||||
| RUN echo "@community https://nl.alpinelinux.org/alpine/v3.10/community" >> /etc/apk/repositories \ | RUN apk -U upgrade \ | ||||||
|  && apk -U upgrade \ |  | ||||||
|  && apk add -t build-dependencies \ |  && apk add -t build-dependencies \ | ||||||
|     gnupg \ |     gnupg \ | ||||||
|     openssl \ |     openssl \ | ||||||
| @@ -18,34 +18,35 @@ RUN echo "@community https://nl.alpinelinux.org/alpine/v3.10/community" >> /etc/ | |||||||
|     nginx \ |     nginx \ | ||||||
|     s6 \ |     s6 \ | ||||||
|     su-exec \ |     su-exec \ | ||||||
|     php7-fpm@community \ |     php8-fpm \ | ||||||
|     php7-curl@community \ |     php8-curl \ | ||||||
|     php7-iconv@community \ |     php8-iconv \ | ||||||
|     php7-xml@community \ |     php8-xml \ | ||||||
|     php7-dom@community \ |     php8-dom \ | ||||||
|     php7-openssl@community \ |     php8-openssl \ | ||||||
|     php7-json@community \ |     php8-json \ | ||||||
|     php7-zlib@community \ |     php8-zlib \ | ||||||
|     php7-pdo_pgsql@community \ |     php8-pdo_pgsql \ | ||||||
|     php7-pdo_mysql@community \ |     php8-pdo_mysql \ | ||||||
|     php7-pdo_sqlite@community \ |     php8-pdo_sqlite \ | ||||||
|     php7-sqlite3@community \ |     php8-sqlite3 \ | ||||||
|     php7-ldap@community \ |     php8-ldap \ | ||||||
|     php7-simplexml@community \ |     php8-simplexml | ||||||
|  && cd /tmp \ | WORKDIR /tmp | ||||||
|  && wget -q https://www.rainloop.net/repository/webmail/rainloop-community-latest.zip \ | RUN set -ex ; \ | ||||||
|  && wget -q https://www.rainloop.net/repository/webmail/rainloop-community-latest.zip.asc \ |     wget -q https://github.com/RainLoop/rainloop-webmail/releases/download/v1.17.0/rainloop-legacy-${RAINLOOP_VERSION}.zip ; \ | ||||||
|  && wget -q https://www.rainloop.net/repository/RainLoop.asc \ |     wget -q https://github.com/RainLoop/rainloop-webmail/releases/download/v1.17.0/rainloop-legacy-${RAINLOOP_VERSION}.zip.asc ; \ | ||||||
|  && gpg --import RainLoop.asc \ |     wget -q https://www.rainloop.net/repository/RainLoop.asc ; \ | ||||||
|  && FINGERPRINT="$(LANG=C gpg --verify rainloop-community-latest.zip.asc rainloop-community-latest.zip 2>&1 \ |     gpg --import RainLoop.asc ; \ | ||||||
|   | sed -n "s#Primary key fingerprint: \(.*\)#\1#p")" \ |     FINGERPRINT="$(LANG=C gpg --verify rainloop-legacy-${RAINLOOP_VERSION}.zip.asc rainloop-legacy-${RAINLOOP_VERSION}.zip 2>&1 | sed -n "s#Primary key fingerprint: \(.*\)#\1#p")" ; \ | ||||||
|  && if [ -z "${FINGERPRINT}" ]; then echo "ERROR: Invalid GPG signature!" && exit 1; fi \ |     if [ -z "${FINGERPRINT}" ]; then echo "ERROR: Invalid GPG signature!" && exit 1; fi ; \ | ||||||
|  && if [ "${FINGERPRINT}" != "${GPG_FINGERPRINT}" ]; then echo "ERROR: Wrong GPG fingerprint!" && exit 1; fi \ |     if [ "${FINGERPRINT}" != "${GPG_FINGERPRINT}" ]; then echo "ERROR: Wrong GPG fingerprint!" && exit 1; fi ; \ | ||||||
|  && mkdir /rainloop && unzip -q /tmp/rainloop-community-latest.zip -d /rainloop \ |     mkdir /rainloop; \ | ||||||
|  && find /rainloop -type d -exec chmod 755 {} \; \ |     unzip -q /tmp/rainloop-legacy-${RAINLOOP_VERSION}.zip -d /rainloop ; \ | ||||||
|  && find /rainloop -type f -exec chmod 644 {} \; \ |     find /rainloop -type d -exec chmod 755 {} \; ; \ | ||||||
|  && apk del build-dependencies \ |     find /rainloop -type f -exec chmod 644 {} \; ; \ | ||||||
|  && rm -rf /tmp/* /var/cache/apk/* /root/.gnupg |     apk del build-dependencies ; \ | ||||||
|  |     rm -rf /tmp/* /var/cache/apk/* /root/.gnupg | ||||||
|  |  | ||||||
| COPY rootfs / | COPY rootfs / | ||||||
| RUN chmod +x /usr/local/bin/run.sh /services/*/run /services/.s6-svscan/* | RUN chmod +x /usr/local/bin/run.sh /services/*/run /services/.s6-svscan/* | ||||||
|   | |||||||
| @@ -1,2 +1,2 @@ | |||||||
| #!/bin/sh | #!/bin/sh | ||||||
| exec php-fpm7 | exec php-fpm8 | ||||||
|   | |||||||
| @@ -1,8 +1,8 @@ | |||||||
| #!/bin/sh | #!/bin/sh | ||||||
|  |  | ||||||
| # Set attachment size limit | # Set attachment size limit | ||||||
| sed -i "s/<UPLOAD_MAX_SIZE>/$UPLOAD_MAX_SIZE/g" /etc/php7/php-fpm.conf /etc/nginx/nginx.conf | sed -i "s/<UPLOAD_MAX_SIZE>/$UPLOAD_MAX_SIZE/g" /etc/php8/php-fpm.conf /etc/nginx/nginx.conf | ||||||
| sed -i "s/<MEMORY_LIMIT>/$MEMORY_LIMIT/g" /etc/php7/php-fpm.conf | sed -i "s/<MEMORY_LIMIT>/$MEMORY_LIMIT/g" /etc/php8/php-fpm.conf | ||||||
|  |  | ||||||
| # Remove postfixadmin-change-password plugin if exist | # Remove postfixadmin-change-password plugin if exist | ||||||
| if [ -d "/rainloop/data/_data_/_default_/plugins/postfixadmin-change-password" ]; then | if [ -d "/rainloop/data/_data_/_default_/plugins/postfixadmin-change-password" ]; then | ||||||
| @@ -14,7 +14,7 @@ if [ "$LOG_TO_STDOUT" = true ]; then | |||||||
|   echo "[INFO] Logging to stdout activated" |   echo "[INFO] Logging to stdout activated" | ||||||
|   chmod o+w /dev/stdout |   chmod o+w /dev/stdout | ||||||
|   sed -i "s/.*error_log.*$/error_log \/dev\/stdout warn;/" /etc/nginx/nginx.conf |   sed -i "s/.*error_log.*$/error_log \/dev\/stdout warn;/" /etc/nginx/nginx.conf | ||||||
|   sed -i "s/.*error_log.*$/error_log = \/dev\/stdout/" /etc/php7/php-fpm.conf |   sed -i "s/.*error_log.*$/error_log = \/dev\/stdout/" /etc/php8/php-fpm.conf | ||||||
| fi | fi | ||||||
|  |  | ||||||
| # Add postfixadmin-change-password plugin | # Add postfixadmin-change-password plugin | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user