2017-02-21 23:50:08 +01:00
|
|
|
# Using https://github.com/smebberson/docker-alpine, which in turn
|
|
|
|
|
# uses https://github.com/just-containers/s6-overlay for a s6 Docker overlay
|
|
|
|
|
FROM smebberson/alpine-base
|
2014-05-19 09:33:44 +02:00
|
|
|
# Initially was based on work of Christian Lück <christian@lueck.tv>
|
2017-02-21 23:50:08 +01:00
|
|
|
LABEL description="A complete, self-hosted Tiny Tiny RSS (TTRSS) environment." \
|
|
|
|
|
maintainer="Andreas Löffler <andy@x86dev.com>"
|
2014-04-26 17:24:57 +02:00
|
|
|
|
2017-02-21 23:50:08 +01:00
|
|
|
RUN set -xe && \
|
|
|
|
|
apk update && apk upgrade && \
|
|
|
|
|
apk add --no-cache --virtual=run-deps \
|
|
|
|
|
nginx git ca-certificates \
|
|
|
|
|
php5 php5-fpm php5-curl php5-dom php5-gd php5-json php5-mcrypt php5-pcntl php5-pdo php5-pdo_pgsql php5-pgsql php5-posix
|
2014-04-26 17:24:57 +02:00
|
|
|
|
2017-02-21 23:50:08 +01:00
|
|
|
# Add user www-data for php-fpm
|
|
|
|
|
# 82 is the standard uid/gid for "www-data" in Alpine
|
|
|
|
|
RUN adduser -u 82 -D -S -G www-data www-data
|
2014-04-26 17:24:57 +02:00
|
|
|
|
2017-02-21 23:50:08 +01:00
|
|
|
COPY root /
|
2015-12-07 22:23:09 +01:00
|
|
|
|
2015-09-04 17:12:37 +02:00
|
|
|
# expose Nginx ports
|
2017-02-21 23:50:08 +01:00
|
|
|
EXPOSE 8080
|
|
|
|
|
EXPOSE 4443
|
2014-04-26 17:24:57 +02:00
|
|
|
|
|
|
|
|
# expose default database credentials via ENV in order to ease overwriting
|
|
|
|
|
ENV DB_NAME ttrss
|
|
|
|
|
ENV DB_USER ttrss
|
|
|
|
|
ENV DB_PASS ttrss
|
|
|
|
|
|
2015-09-05 01:00:23 +02:00
|
|
|
# only run the setup once
|
2017-02-21 23:50:08 +01:00
|
|
|
RUN set -xe && /srv/setup-ttrss.sh
|
2014-05-19 09:33:44 +02:00
|
|
|
|
2015-09-04 17:12:37 +02:00
|
|
|
# clean up
|
2017-02-21 23:50:08 +01:00
|
|
|
RUN set -xe && apk del --progress --purge && rm -rf /var/cache/apk/*
|