This is a small web application to deliver RSS feeds
built by html2rss
via HTTP.
Features:
- serves your own feeds: set up your feed configs in a YAML file. See
html2rss
' README for documentation. - comes with all
html2rss-configs
included. - handles caching and HTTP Cache-Headers.
This web application is distributed in a rolling release
fashion from the master
branch.
๐ Depending on this application? Feel free to donate! Thank you!
Build the URL like this:
The feed config you'd like to use:
lib/html2rss/configs/domainname.tld/whatever.yml
โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ^^^^^^^^^^^^^^^^^^^^^^^^^^^
The corresponding URL:
http://localhost:3000/domainname.tld/whatever.rss
โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ โ ^^^^^^^^^^^^^^^^^^^^^^^^^^^
๐ See file list of all html2rss-configs
.
Install Docker CE and docker run -d -p 3000:3000 gilcreator/html2rss-web
.
To use your private feed configs, mount a feed.yml
into the /app/config/
folder.
docker run -d --name html2rss-web \
--mount type=bind,source="/path/to/your/config/folder,target=/app/config" \
-p 3000:3000 \
gilcreator/html2rss-web
Your private feed specified in the feed.yml
file will be available at http://SERVER-IP:3000/example.rss
. You can change the name of the feed by editing the name of the example
section in the feed.yml
file.
The docker image containrrr/watchtower automatically pulls running docker images and checks for updates. If an update is available, it will start the updated image with the same configuration as the running one.
To start html2rss-web and let watchtower monitor it, save this as start
script:
#!/bin/sh
docker run -d --name html2rss-web \
--mount type=bind,source="/path/to/your/config/folder,target=/app/config" \
-p 3000:3000 \
gilcreator/html2rss-web
docker run -d \
--name watchtower \
-v /var/run/docker.sock:/var/run/docker.sock \
containrrr/watchtower \
--cleanup \
--interval=7200 \
html2rss-web
Watchtower will pull in a 2h interval to check if there's a new image and cleanup (remove the stopped previous image).
A primitive way to automatically update your Docker instance is to set up this script as a cronjob. This has the disadvantage that it restarts the container without first checking whether an update is available or not.
#!/bin/bash
set -e
docker pull -q gilcreator/html2rss-web
(docker stop html2rss-web && docker rm html2rss-web) || :
docker run -d --name html2rss-web --restart=always -p 3000:3000 \
--mount type=bind,source="/home/deploy/html2rss-web/config,target=/app/config" \
gilcreator/html2rss-web
The cronjob for updating every 30 minutes could look like this:
*/30 * * * * /home/deploy/html2rss-web/update > /dev/null 2>&1
Since this repository receives updates frequently, you'd need to update your instance yourself.
- Install Ruby
>= 2.6
. gem install bundler foreman
bundle
foreman start
html2rss-web now listens on port 5000 for requests.
This approach allows you to play around without installing Ruby on your machine. All you need to do is install and run the Docker daemon.
# Build image from Dockerfile and name/tag it as html2rss-web:
docker build -t html2rss-web -f Dockerfile .
# Run the image and name it html2rss-web-dev:
docker run \
--detach \
--mount type=bind,source=$(pwd)/config,target=/app/config \
--name html2rss-web-dev \
html2rss-web
# Open a interactive TTY with the shell `sh`:
docker exec -ti html2rss-web-dev sh
# Stop and cleanup container
docker stop html2rss-web-dev
docker rm html2rss-web-dev
# Remove the image
docker rmi html2rss-web
Websites often change their markup. To get notified when one of your own configs
break, use the /health_check.txt
endpoint.
It will respond with success
if your feeds are generatable.
Otherwise it will not print success
, but states the broken config names.
Name | Description |
---|---|
PORT |
default: 3000 |
RACK_ENV |
default: 'development' |
RACK_TIMEOUT_SERVICE_TIMEOUT |
default: 15 |
WEB_CONCURRENCY |
default: 2 |
WEB_MAX_THREADS |
default: 5 |