Now based on Alpine Linux and s6 as supervisor, resulting in a much smaller Docker image. See README.md for details and other additions.

This commit is contained in:
x86dev 2017-02-21 23:50:08 +01:00
parent 16230d1e5f
commit d7247f6861
23 changed files with 199 additions and 131 deletions

View File

@ -1,59 +1,33 @@
FROM kdelfour/supervisor-docker # 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
# Initially was based on work of Christian Lück <christian@lueck.tv> # Initially was based on work of Christian Lück <christian@lueck.tv>
MAINTAINER Andreas Löffler <andy@x86dev.com> LABEL description="A complete, self-hosted Tiny Tiny RSS (TTRSS) environment." \
maintainer="Andreas Löffler <andy@x86dev.com>"
RUN DEBIAN_FRONTEND=noninteractive apt-get update && apt-get install -y \ RUN set -xe && \
nginx git ca-certificates php5-fpm php5-cli php5-curl php5-gd php5-json php5-mcrypt php5-pgsql 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
# add ttrss as the only Nginx site # Add user www-data for php-fpm
ADD ttrss-nginx.conf /etc/nginx/sites-available/ttrss # 82 is the standard uid/gid for "www-data" in Alpine
RUN ln -s /etc/nginx/sites-available/ttrss /etc/nginx/sites-enabled/ttrss RUN adduser -u 82 -D -S -G www-data www-data
RUN rm /etc/nginx/sites-enabled/default
# patch php5-fpm configuration so that it does not daemonize itself. This is COPY root /
# needed so that runit can watch its state and restart it if it crashes etc.
RUN sed -i -e "s/;daemonize\s*=\s*yes/daemonize = no/g" /etc/php5/fpm/php-fpm.conf
# patch the php-fpm's listening method to _always_ use a unix socket
# note: if not done correctly this will result in a "502 Bad Gateway" error
# (see /var/log/nginx/error.log for more information then)
RUN sed -i -e "s/listen\s*=.*/listen = \/var\/run\/php5-fpm.sock/g" /etc/php5/fpm/pool.d/www.conf
# enable PHP5 modules
RUN php5enmod mcrypt
# expose Nginx ports # expose Nginx ports
EXPOSE 80 EXPOSE 8080
EXPOSE 443 EXPOSE 4443
# expose default database credentials via ENV in order to ease overwriting # expose default database credentials via ENV in order to ease overwriting
ENV DB_NAME ttrss ENV DB_NAME ttrss
ENV DB_USER ttrss ENV DB_USER ttrss
ENV DB_PASS ttrss ENV DB_PASS ttrss
# always re-configure database with current ENV when RUNning container, then monitor all services
RUN mkdir -p /srv
ADD ttrss-utils.php /srv/ttrss-utils.php
ADD ttrss-configure-db.php /srv/ttrss-configure-db.php
ADD ttrss-configure-plugin-mobilize.php /srv/ttrss-configure-plugin-mobilize.php
ADD ttrss-plugin-mobilize.pgsql /srv/ttrss-plugin-mobilize.pgsql
ADD setup-ttrss.sh /srv/setup-ttrss.sh
ADD update-ttrss.sh /srv/update-ttrss.sh
ADD start-ttrss.sh /srv/start-ttrss.sh
RUN mkdir -p /etc/supervisor/conf.d
ADD service-nginx.conf /etc/supervisor/conf.d/nginx.conf
ADD service-php5-fpm.conf /etc/supervisor/conf.d/php5.conf
ADD service-ttrss-daemon.conf /etc/supervisor/conf.d/ttrss-daemon.conf
ADD service-ttrss-update.conf /etc/supervisor/conf.d/ttrss-update.conf
# only run the setup once # only run the setup once
RUN /srv/setup-ttrss.sh RUN set -xe && /srv/setup-ttrss.sh
# clean up # clean up
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* RUN set -xe && apk del --progress --purge && rm -rf /var/cache/apk/*
# start supervisord
WORKDIR /srv
CMD ["/srv/start-ttrss.sh"]

View File

@ -2,9 +2,12 @@
This Dockerfile installs Tiny Tiny RSS (TT-RSS) with the following features: This Dockerfile installs Tiny Tiny RSS (TT-RSS) with the following features:
- **New:** Rolling release support: Updates TT-RSS automatically every day - **New:** Based on [Docker-Alpine](https://github.com/smebberson/docker-alpine) and [s6][nginx-proxy](http://skarnet.org/software/s6/) as the supervisor
- **New:** Works nicely with jwilder's [nginx-proxy](https://github.com/jwilder/nginx-proxy), e.g. to use for Let's Encrypt SSL certificates - **New:** Small and lightweight image size (about 100 MB)
- Rolling release support: Updates TT-RSS automatically every day
- Works nicely with jwilder's [nginx-proxy](https://github.com/jwilder/nginx-proxy), e.g. to use for Let's Encrypt SSL certificates
- Integrated [Feedly theme](https://github.com/levito/tt-rss-feedly-theme) - Integrated [Feedly theme](https://github.com/levito/tt-rss-feedly-theme)
- **New:** Integrated [FeedIron plugin](https://github.com/m42e/ttrss_plugin-feediron) to get modify feeds
- Integrated [Mobilize plugin](https://github.com/sepich/tt-rss-mobilize) for using Readability, Instapaper + Google Mobilizer - Integrated [Mobilize plugin](https://github.com/sepich/tt-rss-mobilize) for using Readability, Instapaper + Google Mobilizer
- Integrated [News+ plugin](https://github.com/hrk/tt-rss-newsplus-plugin) for [News+](https://play.google.com/store/apps/details?id=com.noinnion.android.newsplus) on Android - Integrated [News+ plugin](https://github.com/hrk/tt-rss-newsplus-plugin) for [News+](https://play.google.com/store/apps/details?id=com.noinnion.android.newsplus) on Android
- Optional: Self-signed 2048-bit RSA TLS certificate for accessing TT-RSS via https - Optional: Self-signed 2048-bit RSA TLS certificate for accessing TT-RSS via https
@ -35,7 +38,7 @@ Just start up a new database container:
Next, run the actual TT-RSS instance by doing a: Next, run the actual TT-RSS instance by doing a:
```bash ```bash
# docker run -d --link $DB:db -p 80:80 --name ttrss x86dev/docker-ttrss # docker run -d --link $DB:db -p 80:8080 --name ttrss x86dev/docker-ttrss
``` ```
Running this command for the first time will download the image automatically. Running this command for the first time will download the image automatically.
@ -57,13 +60,17 @@ Password: password
Obviously, you're recommended to change those ASAP. Obviously, you're recommended to change those ASAP.
## Enabling SSL/TLS support
For enabling SSL/TLS support with a self-signed certificate you have to add `-e TTRSS_SSL_ENABLED=1` ## Enabling SSL/TLS encryption support
For enabling SSL/TLS support with a self-signed certificate you have to add `-e TTRSS_SSL_ENABLED=1 -p 443:4443`
when running your TT-RSS container. Then you can access TT-RSS via: `https://<yourhost>`. when running your TT-RSS container. Then you can access TT-RSS via: `https://<yourhost>`.
**Warning: Running services unencrypted on the Internet is not recommended!**
The container also has been successfully tested with Let's Encrypt certificates. The container also has been successfully tested with Let's Encrypt certificates.
## Reverse proxy support ## Reverse proxy support
A nice thing to have is jwilder's [nginx-proxy](https://github.com/jwilder/nginx-proxy) as a separate A nice thing to have is jwilder's [nginx-proxy](https://github.com/jwilder/nginx-proxy) as a separate
@ -73,7 +80,7 @@ That way you easily can integrate your TT-RSS instance with an existing domain b
(e.g. https://ttrss.yourdomain.com). In combination with an official Let's Encrypt certificate you (e.g. https://ttrss.yourdomain.com). In combination with an official Let's Encrypt certificate you
can get a nice A+ encryption/security rating over at [SSLLabs](https://www.ssllabs.com/ssltest/). can get a nice A+ encryption/security rating over at [SSLLabs](https://www.ssllabs.com/ssltest/).
Never run your services unencrypted! **Never run your services unencrypted!**
## Installation walkthrough ## Installation walkthrough
@ -86,6 +93,7 @@ database instance and configuration you're relying on.
Also, this makes this container quite disposable, as it doesn't store any sensitive Also, this makes this container quite disposable, as it doesn't store any sensitive
information at all. information at all.
### Starting a database instance ### Starting a database instance
This container requires a PostgreSQL database instance. You're free to pick (or build) This container requires a PostgreSQL database instance. You're free to pick (or build)
@ -175,15 +183,16 @@ When running this docker container you don't need to worry anymore how and when
update TT-RSS. Since TT-RSS has a so-called "rolling release" model since some time update TT-RSS. Since TT-RSS has a so-called "rolling release" model since some time
(which essentially means that there won't be any specific versions like 1.0, 1.1 etc), (which essentially means that there won't be any specific versions like 1.0, 1.1 etc),
this container takes the burden any checks for updates of TT-RSS and the accompanied this container takes the burden any checks for updates of TT-RSS and the accompanied
plugins/themes every day via an own update script (see `update-ttrss.sh`). plugins/themes every day via an own update script (see `root/srv/update-ttrss.sh`).
By default the update script checks every 24 hours if there are updates for TT-RSS, By default the update script checks every 24 hours if there are updates for TT-RSS,
the plugins or the theme(s) available. the plugins or the theme(s) available.
If you want to change the update interval you just need to edit the file If you want to change the update interval you just need to edit the file
`service-ttrss-update.conf` and change the `--wait-exit 24h` to fit your needs, whereas `root/etc/services.d/ttrss-updater/run` and change the `--wait-exit 24h` to fit your needs, whereas
the suffix `h` stands for hours, `m` for minutes and `s` for seconds. the suffix `h` stands for hours, `m` for minutes and `s` for seconds.
### Want to contribute? ### Want to contribute?
You think you have something which absolutely must be part of this container, implemented You think you have something which absolutely must be part of this container, implemented

View File

@ -0,0 +1,2 @@
#!/usr/bin/with-contenv sh
cd /srv && ./setup-ttrss.sh

75
root/etc/nginx/nginx.conf Normal file
View File

@ -0,0 +1,75 @@
user www-data;
worker_processes auto;
pid /tmp/nginx.pid;
daemon off;
events {
worker_connections 1024;
use epoll;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log debug;
sendfile on;
keepalive_timeout 15;
keepalive_disable msie6;
keepalive_requests 100;
tcp_nopush on;
tcp_nodelay on;
server_tokens off;
fastcgi_temp_path /tmp/fastcgi 1 2;
client_body_temp_path /tmp/client_body 1 2;
proxy_temp_path /tmp/proxy 1 2;
uwsgi_temp_path /tmp/uwsgi 1 2;
scgi_temp_path /tmp/scgi 1 2;
gzip off;
server
{
listen 4443;
root /var/www/ttrss;
ssl on;
ssl_certificate /etc/ssl/certs/ttrss.crt;
ssl_certificate_key /etc/ssl/private/ttrss.key;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
ssl_ciphers "ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA";
index index.php index.html;
client_max_body_size 100M;
location / {
try_files $uri $uri/ =404;
}
location ~ \.php$ {
fastcgi_split_path_info ^(.*\.php)(/.*)?$;
fastcgi_pass unix:/tmp/php-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_intercept_errors off;
fastcgi_buffer_size 16k;
fastcgi_buffers 4 16k;
}
location ~ /\.ht {
deny all;
}
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/tmp/php-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
}
}

View File

@ -0,0 +1,19 @@
[global]
daemonize = no
[www]
user = www-data
listen.owner = www-data
listen.group = www-data
listen = /tmp/php-fpm.sock
pm = dynamic
pm.max_children = 15
pm.start_servers = 2
pm.min_spare_servers = 1
pm.max_spare_servers = 6
chdir = /var/www/ttrss/
request_terminate_timeout = 0
env[PATH] = /usr/local/bin:/usr/bin:/bin
php_admin_value[max_execution_time] = 10800
php_admin_value[max_input_time] = 3600
php_admin_value[expose_php] = Off

View File

@ -0,0 +1,3 @@
#!/bin/sh
exit 0

View File

@ -0,0 +1,2 @@
#!/bin/sh
exec nginx

View File

@ -0,0 +1,2 @@
#!/bin/sh
exec php-fpm

View File

@ -0,0 +1,7 @@
#!/bin/sh
while true; do
cd /var/www/ttrss
php -f /var/www/ttrss/update_daemon2.php
sleep 5m
done

View File

@ -0,0 +1,6 @@
#!/bin/sh
while true; do
/srv/update-ttrss.sh
sleep 24h
done

View File

@ -8,8 +8,11 @@ setup_nginx()
TTRSS_HOST=ttrss TTRSS_HOST=ttrss
fi fi
NGINX_CONF=/etc/nginx/nginx.conf
if [ "$TTRSS_SSL_ENABLED" = "1" ]; then if [ "$TTRSS_SSL_ENABLED" = "1" ]; then
if [ ! -f "/etc/ssl/private/ttrss.key" ]; then if [ ! -f "/etc/ssl/private/ttrss.key" ]; then
echo "Setup: Generating self-signed certificate ..."
# Generate the TLS certificate for our Tiny Tiny RSS server instance. # Generate the TLS certificate for our Tiny Tiny RSS server instance.
openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 \ openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 \
-subj "/C=US/ST=World/L=World/O=$TTRSS_HOST/CN=$TTRSS_HOST" \ -subj "/C=US/ST=World/L=World/O=$TTRSS_HOST/CN=$TTRSS_HOST" \
@ -19,14 +22,13 @@ setup_nginx()
chmod 600 "/etc/ssl/private/ttrss.key" chmod 600 "/etc/ssl/private/ttrss.key"
chmod 600 "/etc/ssl/certs/ttrss.crt" chmod 600 "/etc/ssl/certs/ttrss.crt"
else else
echo "Setup: !!! WARNING !!! Turning OFF SSL/TLS !!! WARNING !!!"
echo "Setup: This is not recommended for a production server. You have been warned."
# Turn off SSL. # Turn off SSL.
sed -i -e "s/listen\s*443\s*;/listen 80;/g" /etc/nginx/sites-available/ttrss sed -i -e "s/listen\s*4443\s*;/listen 8080;/g" ${NGINX_CONF}
sed -i -e "s/ssl\s*on\s*;/ssl off;/g" /etc/nginx/sites-available/ttrss sed -i -e "s/ssl\s*on\s*;/ssl off;/g" ${NGINX_CONF}
sed -i -e "/\s*ssl_*/d" /etc/nginx/sites-available/ttrss sed -i -e "/\s*ssl_*/d" ${NGINX_CONF}
fi fi
# Configure Nginx so that is doesn't show its version number in the HTTP headers.
sed -i -e "s/.*server_tokens\s.*/server_tokens off;/g" /etc/nginx/nginx.conf
} }
setup_ttrss() setup_ttrss()
@ -34,10 +36,11 @@ setup_ttrss()
TTRSS_PATH=/var/www/ttrss TTRSS_PATH=/var/www/ttrss
mkdir -p ${TTRSS_PATH} mkdir -p ${TTRSS_PATH}
git clone https://tt-rss.org/gitlab/fox/tt-rss.git ${TTRSS_PATH} git clone --depth=1 https://tt-rss.org/gitlab/fox/tt-rss.git ${TTRSS_PATH}
git clone https://github.com/sepich/tt-rss-mobilize.git ${TTRSS_PATH}/plugins/mobilize git clone --depth=1 https://github.com/sepich/tt-rss-mobilize.git ${TTRSS_PATH}/plugins/mobilize
git clone https://github.com/hrk/tt-rss-newsplus-plugin.git ${TTRSS_PATH}/plugins/api_newsplus git clone --depth=1 https://github.com/hrk/tt-rss-newsplus-plugin.git ${TTRSS_PATH}/plugins/api_newsplus
git clone https://github.com/levito/tt-rss-feedly-theme.git ${TTRSS_PATH}/themes/feedly-git git clone --depth=1 https://github.com/m42e/ttrss_plugin-feediron.git ${TTRSS_PATH}/plugins/feediron
git clone --depth=1 https://github.com/levito/tt-rss-feedly-theme.git ${TTRSS_PATH}/themes/feedly-git
# Add initial config. # Add initial config.
cp ${TTRSS_PATH}/config.php-dist ${TTRSS_PATH}/config.php cp ${TTRSS_PATH}/config.php-dist ${TTRSS_PATH}/config.php

9
root/srv/start-ttrss.sh Executable file
View File

@ -0,0 +1,9 @@
#!/bin/sh
set -e
# Update configuration. This is necessary for entering the current IP + PORT of the database.
/srv/update-ttrss.sh --no-start
# Call the image's init script which in turn calls the s6 supervisor then.
/init

View File

@ -3,26 +3,22 @@ set -e
TTRSS_PATH=/var/www/ttrss TTRSS_PATH=/var/www/ttrss
# Note: Make sure to keep the actual updater service ("ttrss-update") alive,
# otherwise this script will be killed and everyting goes nuts.
TTRSS_SUPERVISORD_SERVICES="ttrss-daemon nginx php5-fpm"
update_ttrss() update_ttrss()
{ {
echo "Updating: Tiny Tiny RSS" echo "Updating: Tiny Tiny RSS"
( cd ${TTRSS_PATH} && git pull origin master ) ( cd ${TTRSS_PATH} && git pull origin HEAD )
if [ -n "$DB_PORT" ]; then if [ -n "$DB_PORT" ]; then
echo "Updating: Database" echo "Updating: Database"
php /srv/ttrss-configure-db.php php -f /srv/ttrss-configure-db.php
php /srv/ttrss-configure-plugin-mobilize.php php -f /srv/ttrss-configure-plugin-mobilize.php
fi fi
} }
update_plugin_mobilize() update_plugin_mobilize()
{ {
echo "Updating: Mobilize plugin" echo "Updating: Mobilize plugin"
( cd ${TTRSS_PATH}/plugins/mobilize && git pull origin master ) ( cd ${TTRSS_PATH}/plugins/mobilize && git pull origin HEAD )
# Patch ttrss-mobilize plugin for getting it to work. # Patch ttrss-mobilize plugin for getting it to work.
sed -i -e "s/<?$/<?php/g" ${TTRSS_PATH}/plugins/mobilize/m.php sed -i -e "s/<?$/<?php/g" ${TTRSS_PATH}/plugins/mobilize/m.php
@ -32,16 +28,22 @@ update_plugin_mobilize()
update_plugin_newsplus() update_plugin_newsplus()
{ {
echo "Updating: News+ plugin" echo "Updating: News+ plugin"
( cd ${TTRSS_PATH}/plugins/api_newsplus && git pull origin master ) ( cd ${TTRSS_PATH}/plugins/api_newsplus && git pull origin HEAD )
# Link plugin to TTRSS. # Link plugin to TTRSS.
ln -f -s ${TTRSS_PATH}/plugins/api_newsplus/api_newsplus/init.php ${TTRSS_PATH}/plugins/api_newsplus/init.php ln -f -s ${TTRSS_PATH}/plugins/api_newsplus/api_newsplus/init.php ${TTRSS_PATH}/plugins/api_newsplus/init.php
} }
update_plugin_feediron()
{
echo "Updating: FeedIron"
( cd ${TTRSS_PATH}/plugins/feediron && git pull origin HEAD )
}
update_theme_feedly() update_theme_feedly()
{ {
echo "Updating: Feedly theme" echo "Updating: Feedly theme"
( cd ${TTRSS_PATH}/themes/feedly-git && git pull origin master ) ( cd ${TTRSS_PATH}/themes/feedly-git && git pull origin HEAD )
# Link theme to TTRSS. # Link theme to TTRSS.
ln -f -s ${TTRSS_PATH}/themes/feedly-git/feedly ${TTRSS_PATH}/themes/feedly ln -f -s ${TTRSS_PATH}/themes/feedly-git/feedly ${TTRSS_PATH}/themes/feedly
@ -50,17 +52,28 @@ update_theme_feedly()
update_common() update_common()
{ {
# Apply ownership of ttrss + addons to www-data. echo "Updating: Updating permissions"
chown www-data:www-data -R ${TTRSS_PATH} for dir in /etc/nginx /etc/php5 /var/log /var/lib/nginx /tmp /etc/services.d; do
if $(find $dir ! -user $UID -o ! -group $GID | egrep '.' -q); then
echo "Updating: Updating permissions in $dir..."
chown -R $UID:$GID $dir
else
echo "Updating: Permissions in $dir are correct"
fi
done
chown -R www-data:www-data ${TTRSS_PATH}
echo "Updating: updating permissions done"
} }
echo "Update: Updating rolling release ..." echo "Update: Updating rolling release ..."
echo "Update: Stopping all ..." echo "Update: Stopping all ..."
supervisorctl stop ${TTRSS_SUPERVISORD_SERVICES}
update_ttrss update_ttrss
update_plugin_mobilize update_plugin_mobilize
update_plugin_newsplus update_plugin_newsplus
update_plugin_feediron
update_theme_feedly update_theme_feedly
update_common update_common
@ -68,7 +81,6 @@ echo "Update: Done."
if [ "$1" != "--no-start" ]; then if [ "$1" != "--no-start" ]; then
echo "Update: Starting all ..." echo "Update: Starting all ..."
supervisorctl start ${TTRSS_SUPERVISORD_SERVICES}
fi fi
if [ "$1" = "--wait-exit" ]; then if [ "$1" = "--wait-exit" ]; then
UPDATE_WAIT_TIME=$2 UPDATE_WAIT_TIME=$2

View File

@ -1,4 +0,0 @@
[program:nginx]
command=/usr/sbin/nginx -g "daemon off;"
user=root
redirect_stderr=true

View File

@ -1,4 +0,0 @@
[program:php5-fpm]
command=/usr/sbin/php5-fpm
user=root
redirect_stderr=true

View File

@ -1,4 +0,0 @@
[program:ttrss-daemon]
command=/usr/bin/php /var/www/ttrss/update_daemon2.php
user=www-data
redirect_stderr=true

View File

@ -1,6 +0,0 @@
[program:ttrss-update]
command=/srv/update-ttrss.sh --wait-exit 24h
user=root
autorestart=true
exitcodes=0
redirect_stderr=true

View File

@ -1,13 +0,0 @@
#!/bin/sh
set -e
# Make sure an old instance of supervisord is not running anymore.
supervisorctl stop all
# Update configuration. This is necessary for entering the current IP + PORT of the database.
/srv/update-ttrss.sh --no-start
# Start supervisord.
# This will start all other dependencies.
supervisord -c /etc/supervisor/supervisord.conf

View File

@ -1,24 +0,0 @@
server {
listen 443;
root /var/www/ttrss;
ssl on;
ssl_certificate /etc/ssl/certs/ttrss.crt;
ssl_certificate_key /etc/ssl/private/ttrss.key;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_prefer_server_ciphers on;
ssl_ciphers "AES256+EECDH:AES256+EDH:!aNULL";
index index.php index.html;
location / {
try_files $uri $uri/ =404;
}
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
}