supervisor based runner

This commit is contained in:
2018-12-15 10:20:17 +01:00
parent be7f703fe5
commit bef7237e3c
2 changed files with 25 additions and 1 deletions

View File

@@ -28,6 +28,7 @@ EXPOSE 80 443
COPY nginx.conf /etc/nginx/conf.d/default.conf
COPY php-fpm.conf /etc/php7/php-fpm.d/ttrss.conf
COPY install-db.php /var/lib/tt-rss-install/install-db.php
COPY supervisor.conf /var/lib/tt-rss-install/supervisor.conf
ADD https://git.tt-rss.org/fox/tt-rss/archive/18.12.tar.gz /tmp/ttrss.tar.gz
RUN tar -xzf /tmp/ttrss.tar.gz -C /var/lib
@@ -39,4 +40,4 @@ RUN \
chmod -R 777 /var/lib/tt-rss/feed-icons && \
chmod -R 777 /var/lib/tt-rss/lock
CMD php-fpm7 && nginx -g "daemon off;"
CMD supervisord -c /var/lib/tt-rss-install/supervisor.conf

23
supervisor.conf Normal file
View File

@@ -0,0 +1,23 @@
[supervisord]
nodaemon=true
[program:nginx]
command=nginx -g "daemon off;"
autostart=true
autorestart=true
stdout_events_enabled=true
stderr_events_enabled=true
[program:php-fpm]
command=php-fpm7
autostart=true
autorestart=true
stdout_events_enabled=true
stderr_events_enabled=true
[program:feed-update]
command=php7 /var/lib/tt-rss/update.php --daemon
autostart=true
autorestart=true
stdout_events_enabled=true
stderr_events_enabled=true