Compare commits

...

16 Commits

Author SHA1 Message Date
Robert Kaussow da8b67cf1d enable phpinfo
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-09-14 19:57:30 +02:00
Robert Kaussow 08d4b6feb7 nginx error log to stdout
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-08-02 14:42:14 +02:00
Robert Kaussow 95cb030307 switch to cron based feed updates
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-07-31 09:49:28 +02:00
Robert Kaussow a18df05208 remove chmod from disable_functions
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-07-26 08:26:05 +02:00
Robert Kaussow 1d4c4b2db9 enable opcache by default 2019-07-26 08:25:31 +02:00
Robert Kaussow 166f9d9e31 change log destination to syslog 2019-07-25 14:48:08 +02:00
Robert Kaussow cfe0a52f65 fix php open_basedir
continuous-integration/drone/push Build is passing Details
2019-07-22 09:04:56 +02:00
Robert Kaussow 305893a0bb add ttrss backlink to readme
continuous-integration/drone/push Build is passing Details
2019-07-22 09:01:59 +02:00
Robert Kaussow 67a1082908 change docker hub short description
continuous-integration/drone/push Build is passing Details
2019-07-22 00:53:47 +02:00
Robert Kaussow 69b5a66a03 change docjer hub short description
continuous-integration/drone/push Build is passing Details
2019-07-22 00:52:41 +02:00
Robert Kaussow a197d04db5 change volume names in compose and readme
continuous-integration/drone/push Build is passing Details
2019-07-22 00:51:15 +02:00
Robert Kaussow 0471467e64 fix healthcheck and add cache dir setup
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-07-20 16:19:23 +02:00
Robert Kaussow 578e5d2296 debug healthcheck script
continuous-integration/drone/push Build is passing Details
2019-07-20 16:16:50 +02:00
Robert Kaussow 155f935821 fix cache folders
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-07-20 15:00:28 +02:00
Robert Kaussow 0f5296d027 small fixes in healthcheck and entrypoint script
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-07-20 14:34:59 +02:00
Robert Kaussow 38fc80f338 add healthcheck script
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details
2019-07-17 12:17:40 +02:00
14 changed files with 70 additions and 30 deletions

View File

@ -88,7 +88,7 @@ local PipelineNotifications(depends_on=[]) = {
DOCKERHUB_REPO_PREFIX: "xoxys",
DOCKERHUB_REPO_NAME: "ttrss",
README_PATH: "README.md",
SHORT_DESCRIPTION: "Tiny Tiny RSS - free and open source news feed reader and aggregator"
SHORT_DESCRIPTION: "Tiny Tiny RSS - Free and open source news feed reader and aggregator"
},
when: {
ref: [

View File

@ -79,7 +79,7 @@ steps:
DOCKERHUB_USERNAME:
from_secret: docker_username
README_PATH: README.md
SHORT_DESCRIPTION: Tiny Tiny RSS - free and open source news feed reader and aggregator
SHORT_DESCRIPTION: Tiny Tiny RSS - Free and open source news feed reader and aggregator
when:
ref:
- refs/heads/master
@ -118,6 +118,6 @@ depends_on:
---
kind: signature
hmac: 1be20e6fec87140af3743fe805e738be2a4750a85cc8452332287841c30b699f
hmac: dc21d353585f6faf703b81baa1265634b52543a981c2745f07859dcc41dcabf7
...

View File

@ -23,7 +23,13 @@ RUN apk --update add --virtual .build-deps tar curl && \
curl -SsL -o /etc/php7/browscap.ini https://browscap.org/stream?q=Lite_PHP_BrowsCapINI && \
apk del .build-deps && \
rm -rf /var/cache/apk/* && \
rm -rf /tmp/*
rm -rf /tmp/* && \
mkdir -p /var/lib/php/tmp_upload && \
mkdir -p /var/lib/php/soap_cache && \
mkdir -p /var/lib/php/session && \
chown -R nginx:nginx /var/lib/php/tmp_upload && \
chown -R nginx:nginx /var/lib/php/soap_cache && \
chown -R nginx:nginx /var/lib/php/session
ADD overlay/ /
@ -34,6 +40,6 @@ VOLUME /var/www/app/themes.local
EXPOSE 80
ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]
HEALTHCHECK --interval=30s --timeout=10s --retries=5 CMD wget --quiet --tries=1 --spider http://localhost
HEALTHCHECK --interval=30s --timeout=10s --retries=3 CMD /usr/local/bin/healthcheck.sh
WORKDIR /var/www/app
CMD []

View File

@ -3,7 +3,7 @@
[![Build Status](https://drone.rknet.org/api/badges/docker/ttrss/status.svg)](https://drone.rknet.org/docker/ttrss/)
[![Microbadger](https://images.microbadger.com/badges/image/xoxys/ttrss.svg)](https://microbadger.com/images/xoxys/ttrss "Get your own image badge on microbadger.com")
TT-RSS is an open source web-based news feed (RSS/Atom) reader and aggregator, designed to allow you to read news from any location, while feeling as close to a real desktop application as possible.
TT-RSS is an open source web-based news feed (RSS/Atom) reader and aggregator, designed to allow you to read news from any location, while feeling as close to a real desktop application as possible. This repository is just a wrapper to build a community docker image from [TT-RSS](https://git.tt-rss.org/git/tt-rss) releases.
## Usage
@ -36,9 +36,9 @@ services:
depends_on:
- db
volumes:
- plugins:/var/www/app/plugins.local
- icons:/var/www/app/feed-icons
- themes:/var/www/app/themes.local
- ttrss_plugins:/var/www/app/plugins.local
- ttrss_icons:/var/www/app/feed-icons
- ttrss_themes:/var/www/app/themes.local
db:
image: postgres
@ -52,11 +52,11 @@ services:
volumes:
postgres_data:
driver: local
plugins:
ttrss_plugins:
driver: local
icons:
ttrss_icons:
driver: local
themes:
ttrss_themes:
driver: local
```
@ -114,6 +114,13 @@ PHP_ALLOW_URL_FOPEN=On
PHP_ALLOW_URL_INCLUDE=Off
PHP_DATE_TIMEZONE=Europe/Berlin
PHP_SQL_SAFE_MODE=On
PHP_OPCACHE_ENABLE=On
PHP_OPCACHE_MEMORY_CONSUMPTION=64
PHP_OPCACHE_MAX_ACCELERATED_FILES=2000
PHP_OPCACHE_MAX_WASTED_PERCENTAGE=5
PHP_OPCACHE_INTERNED_STRINGS_BUFFER=4
PHP_OPCACHE_REVALIDATE_FREQ=2
PHP_OPCACHE_SAVE_COMMENTS=1
```
### License

View File

@ -8,9 +8,9 @@ services:
depends_on:
- db
volumes:
- plugins:/var/www/app/plugins.local
- icons:/var/www/app/feed-icons
- themes:/var/www/app/themes.local
- ttrss_plugins:/var/www/app/plugins.local
- ttrss_icons:/var/www/app/feed-icons
- ttrss_themes:/var/www/app/themes.local
db:
image: postgres
@ -24,9 +24,9 @@ services:
volumes:
postgres_data:
driver: local
plugins:
ttrss_plugins:
driver: local
icons:
ttrss_icons:
driver: local
themes:
ttrss_themes:
driver: local

View File

@ -0,0 +1 @@
*/15 * * * * /usr/bin/php /var/www/app/update.php --feeds

View File

@ -16,7 +16,7 @@ http {
keepalive_timeout 65;
server_tokens off;
access_log off;
error_log /dev/stderr;
error_log /dev/stdout;
fastcgi_buffers 16 16k;
fastcgi_buffer_size 32k;

View File

@ -0,0 +1,4 @@
#!/bin/sh
set -e
echo "Container crashed. Exiting..."
exit 1

2
overlay/etc/services.d/.s6-svscan/finish Normal file → Executable file
View File

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

View File

@ -0,0 +1,2 @@
#!/bin/execlineb -P
crond -f

View File

@ -1,2 +0,0 @@
#!/bin/execlineb -P
s6-setuidgid nginx php7 /var/www/app/update_daemon2.php > /dev/null 2>&1

View File

@ -21,7 +21,7 @@ serialize_precision = 17
open_basedir = "/var/www/app:/var/lib/php/tmp_upload:/var/lib/php/session:/var/lib/php/soap_cache"
disable_functions = system, exec, shell_exec, phpinfo, show_source, highlight_file, popen, proc_open, fopen_with_path, dbmopen, dbase_open, putenv, move_uploaded_file, mkdir, rmdir, chmod, rename, filepro, filepro_rowcount, filepro_retrieve, posix_mkfifo
disable_functions = system, exec, shell_exec, show_source, highlight_file, popen, proc_open, fopen_with_path, dbmopen, dbase_open, putenv, move_uploaded_file, mkdir, rmdir, rename, filepro, filepro_rowcount, filepro_retrieve, posix_mkfifo
disable_classes =
;highlight.string = #DD0000
@ -350,17 +350,17 @@ ldap.max_links = -1
;dba.default_handler =
[opcache]
;opcache.enable = 0
opcache.enable = {{ getenv "PHP_OPCACHE_ENABLE" "On" }}
;opcache.enable_cli = 0
;opcache.memory_consumption = 64
;opcache.interned_strings_buffer = 4
;opcache.max_accelerated_files = 2000
;opcache.max_wasted_percentage = 5
opcache.memory_consumption = {{ getenv "PHP_OPCACHE_MEMORY_CONSUMPTION" "64" }}
opcache.interned_strings_buffer = {{ getenv "PHP_OPCACHE_INTERNED_STRINGS_BUFFER" "4" }}
opcache.max_accelerated_files = {{ getenv "PHP_OPCACHE_MAX_ACCELERATED_FILES" "2000" }}
opcache.max_wasted_percentage = {{ getenv "PHP_OPCACHE_MAX_WASTED_PERCENTAGE" "5" }}
;opcache.use_cwd = 1
;opcache.validate_timestamps = 1
;opcache.revalidate_freq = 2
opcache.revalidate_freq = {{ getenv "PHP_OPCACHE_REVALIDATE_FREQ" "2" }}
;opcache.revalidate_path = 0
;opcache.save_comments = 1
opcache.save_comments = {{ getenv "PHP_OPCACHE_MAX_WASTED_PERCENTAGE" "1" }}
;opcache.fast_shutdown = 0
;opcache.enable_file_override = 0
;opcache.optimization_level = 0xffffffff

View File

@ -2,6 +2,11 @@
/usr/local/bin/gomplate -V -o /etc/php7/php.ini -f /etc/templates/php.ini.tmpl
/usr/local/bin/gomplate -V -o /var/www/app/config.php -f /etc/templates/config.php.tmpl
# ensure lock folders exists
mkdir -p /var/www/app/cache/images
mkdir -p /var/www/app/cache/upload
mkdir -p /var/www/app/cache/export
chown -R nginx:nginx /var/www/app/lock
chown -R nginx:nginx /var/www/app/cache
chown -R nginx:nginx /var/www/app/feed-icons

View File

@ -0,0 +1,17 @@
#!/bin/sh
set -eo pipefail
URL=http://localhost
wget --quiet --tries=1 --spider ${URL}
[ $? -ne 0 ] && exit 1
CONTENT=$(wget --quiet -O - ${URL})
case "$CONTENT" in
*Exception*) exit 1 ;;
*alert-*alert-*SELF_URL_PATH*) exit 1 ;;
*alert-*SELF_URL_PATH*alert-*) exit 1 ;;
*SELF_URL_PATH*alert-*alert-*) exit 1 ;;
esac
exit 0