Merge branch 'update-ttrss' of kemonine/docs into master
This commit is contained in:
commit
0395f590e4
|
@ -16,38 +16,7 @@ docker exec -it postgres psql -U postgres
|
||||||
create role ttrss nocreatedb nocreaterole login PASSWORD 'password';
|
create role ttrss nocreatedb nocreaterole login PASSWORD 'password';
|
||||||
create database ttrss owner=ttrss encoding=UTF8;
|
create database ttrss owner=ttrss encoding=UTF8;
|
||||||
|
|
||||||
cat > /root/docker/ttrss.sh << EOF
|
wget -O ttrss.sh https://git.lollipopcloud.solutions/lollipop-docker/misc/raw/branch/master/run_ttrss.sh
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
ARCH=\`arch\`
|
|
||||||
HUBIMAGE=""
|
|
||||||
|
|
||||||
# Cleanup arch/container image here
|
|
||||||
if [ \$ARCH == "aarch64" ]
|
|
||||||
then
|
|
||||||
echo "64bit arm"
|
|
||||||
HUBIMAGE="lsioarmhf/tt-rss-aarch64:latest"
|
|
||||||
else
|
|
||||||
echo "32bit arm"
|
|
||||||
HUBIMAGE="lsioarmhf/tt-rss:latest"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Cleanup existing container
|
|
||||||
docker stop ttrss
|
|
||||||
docker rm ttrss
|
|
||||||
|
|
||||||
# Re-run/create container with latest image
|
|
||||||
docker run \\
|
|
||||||
--name ttrss \\
|
|
||||||
--restart unless-stopped \\
|
|
||||||
--net docker-private \\
|
|
||||||
--ip 172.30.13.13 \\
|
|
||||||
-e TZ=UTC \\
|
|
||||||
-e DEBUG=1 \\
|
|
||||||
-v /var/ttrss:/config \\
|
|
||||||
\$HUBIMAGE
|
|
||||||
EOF
|
|
||||||
|
|
||||||
chmod a+x /root/docker/ttrss.sh
|
chmod a+x /root/docker/ttrss.sh
|
||||||
|
|
||||||
```
|
```
|
||||||
|
@ -56,26 +25,11 @@ chmod a+x /root/docker/ttrss.sh
|
||||||
|
|
||||||
Simply execute ```/root/docker/ttrss.sh``` to update/run TT-RSS.
|
Simply execute ```/root/docker/ttrss.sh``` to update/run TT-RSS.
|
||||||
|
|
||||||
## Serving Via Caddy
|
## Cron For Feed Updates
|
||||||
|
|
||||||
``` bash
|
``` bash
|
||||||
|
|
||||||
cat > /etc/caddy/services/ttrss.conf <<EOF
|
*/10 * * * * docker exec --user 991 -it ttrss /usr/bin/php /config/www/tt-rss/update.php --feeds --quiet
|
||||||
# TT-RSS proxy
|
|
||||||
ttrss.domain.tld {
|
|
||||||
tls user@domain.tld
|
|
||||||
|
|
||||||
redir 301 {
|
|
||||||
if {scheme} is http
|
|
||||||
/ https://ttrss.domain.tld{uri}
|
|
||||||
}
|
|
||||||
|
|
||||||
log /var/log/caddy/ttrss.log
|
|
||||||
proxy / 172.30.13.13:80 {
|
|
||||||
transparent
|
|
||||||
}
|
|
||||||
}
|
|
||||||
EOF
|
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
Reference in New Issue