Renovate Bot | 5b92936 | 2023-03-06 06:00:46 +0000 | [diff] [blame^] | 1 | FROM alpine:3.17 |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 2 | MAINTAINER Silvio Fricke <silvio.fricke@gmail.com> |
| 3 | |
Matthias Andreas Benkard | b30a4bc | 2019-12-31 13:23:36 +0100 | [diff] [blame] | 4 | ARG HUBZILLAVERSION=4.4.1 |
| 5 | ARG HUBZILLAADDONSVERSION=4.4.1 |
Matthias Andreas Benkard | af07b8f | 2018-07-16 06:57:40 +0200 | [diff] [blame] | 6 | ARG REFRESH=0 |
| 7 | |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 8 | ENTRYPOINT ["/start.sh"] |
| 9 | VOLUME /data |
| 10 | |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 11 | RUN set -ex \ |
| 12 | && apk update \ |
| 13 | && apk upgrade \ |
| 14 | && apk add \ |
| 15 | bash \ |
| 16 | curl \ |
| 17 | dcron \ |
| 18 | gd \ |
| 19 | nginx \ |
| 20 | openssl \ |
| 21 | php5 \ |
Matthias Andreas Benkard | af07b8f | 2018-07-16 06:57:40 +0200 | [diff] [blame] | 22 | php5-ctype \ |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 23 | php5-curl \ |
Matthias Andreas Benkard | af07b8f | 2018-07-16 06:57:40 +0200 | [diff] [blame] | 24 | php5-dom \ |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 25 | php5-fpm \ |
| 26 | php5-gd \ |
| 27 | php5-json \ |
Matthias Andreas Benkard | af07b8f | 2018-07-16 06:57:40 +0200 | [diff] [blame] | 28 | php5-mcrypt \ |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 29 | php5-pdo_mysql \ |
| 30 | php5-pdo_pgsql \ |
| 31 | php5-openssl \ |
| 32 | php5-xml \ |
| 33 | php5-zip \ |
Matthias Andreas Benkard | af07b8f | 2018-07-16 06:57:40 +0200 | [diff] [blame] | 34 | php5-iconv \ |
| 35 | && mkdir -p /run/nginx /hubzilla /hubzilla/addon \ |
Matthias Andreas Benkard | 8878f92 | 2018-07-17 21:16:53 +0200 | [diff] [blame] | 36 | && curl https://framagit.org/hubzilla/core/-/archive/${HUBZILLAVERSION}/core-${HUBZILLAVERSION}.tar.gz | tar -xz --strip-components=1 -C /hubzilla -f - \ |
| 37 | && curl https://framagit.org/hubzilla/addons/-/archive/${HUBZILLAADDONSVERSION}/addons-${HUBZILLAADDONSVERSION}.tar.gz | tar -xz --strip-components=1 -C /hubzilla/addon -f - \ |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 38 | && chown nginx:nginx -R /hubzilla \ |
| 39 | && chmod 0777 /hubzilla \ |
| 40 | && sed -i 's/;cgi.fix_pathinfo=1/cgi.fix_pathinfo=0/' /etc/php5/php.ini \ |
Matthias Andreas Benkard | af07b8f | 2018-07-16 06:57:40 +0200 | [diff] [blame] | 41 | && sed -i 's/pm.max_children = 5/pm.max_children = 16/' /etc/php5/php-fpm.conf \ |
Matthias Andreas Benkard | c7d492a | 2017-07-29 10:02:55 +0200 | [diff] [blame] | 42 | && echo "*/###HUBZILLAINTERVAL### * * * * cd /hubzilla; /usr/bin/php Zotlabs/Daemon/Master.php Cron" > /hubzilla-cron.txt |
Matthias Andreas Benkard | af07b8f | 2018-07-16 06:57:40 +0200 | [diff] [blame] | 43 | |
| 44 | WORKDIR /hubzilla |
| 45 | COPY addons/longfeed.patch longfeed.patch |
| 46 | RUN patch -p1 <longfeed.patch |
| 47 | RUN rm longfeed.patch |
| 48 | WORKDIR / |
| 49 | |
| 50 | COPY addons/nginx-server.conf /etc/nginx/conf.d/default.conf |
| 51 | COPY addons/start.sh /start.sh |
| 52 | |
| 53 | ENV SERVERNAME=127.0.0.1 |
| 54 | ENV HUBZILLAINTERVAL=10 |