From 546f07cc791556aae909572fe16b70efd382640a Mon Sep 17 00:00:00 2001 From: litneet64 Date: Sun, 21 Apr 2024 00:38:39 -0400 Subject: [PATCH] add detailed usage for rsshub --- apps/rsshub/config.json | 2 +- apps/rsshub/metadata/description.md | 35 ++++++++++++++++++++++++----- 2 files changed, 31 insertions(+), 6 deletions(-) diff --git a/apps/rsshub/config.json b/apps/rsshub/config.json index 183e1434..e602e699 100644 --- a/apps/rsshub/config.json +++ b/apps/rsshub/config.json @@ -7,7 +7,7 @@ "description": "RSSHub is an open source, easy to use, and extensible RSS feed generator. It's capable of generating RSS feeds from pretty much everything.", "tipi_version": 1, "version": "2024-04-17", - "categories": ["utilities", "media", "automation"], + "categories": ["utilities", "media"], "short_desc": "Everything is RSSible with RSSHub", "author": "https://github.com/DIYgod", "source": "https://github.com/DIYgod/RSSHub", diff --git a/apps/rsshub/metadata/description.md b/apps/rsshub/metadata/description.md index dde899dc..015418eb 100644 --- a/apps/rsshub/metadata/description.md +++ b/apps/rsshub/metadata/description.md @@ -1,7 +1,7 @@ -![](https://camo.githubusercontent.com/ceaf8f7b5c2b0f5b71013f5553cd4e71dfbc47787928a2ec1cfe0e41a7a0b99c/68747470733a2f2f646f63732e7273736875622e6170702f696d672f6c6f676f2e706e67) - # RSSHub +![](https://camo.githubusercontent.com/ceaf8f7b5c2b0f5b71013f5553cd4e71dfbc47787928a2ec1cfe0e41a7a0b99c/68747470733a2f2f646f63732e7273736875622e6170702f696d672f6c6f676f2e706e67) + ## Introduction Introduction @@ -15,11 +15,36 @@ RSSHub can be used with browser extension [RSSHub Radar](https://github.com/DIYg [English docs](https://docs.rsshub.app/) | [Telegram Group](https://t.me/rsshub) | [Telegram Channel](https://t.me/awesomeRSSHub) | [Twitter](https://twitter.com/intent/follow?screen_name=_RSSHub) | [中文文档](https://docs.rsshub.app/zh/) -## Configuration +## Usage -Must be done via environment variables, either through a custom app.env file or directly modifying the docker-compose.yml file, as detailed in https://runtipi.io/docs/guides/customize-app-config. +In order to generate a feed, a valid URL with parameters has to be appended to the main domain for your RSSHub instance, varying with each different app. More on the how-to's for each supported service or app can be found on [https://docs.rsshub.app/guide/](https://docs.rsshub.app/guide/), and on [https://docs.rsshub.app/guide/parameters](https://docs.rsshub.app/guide/parameters) for filtering/sorting/limiting your feed in a given URL. -More info related to available configuration envvars for RSSHub can be found on https://docs.rsshub.app/deploy/config. +## RSSHub Configuration / Adding Accounts + +Configuration for your own instance must be done via environment variables, either through uncommenting an envvar in the already made .env file at `{$APP_DATA_DIR}/app-data/data/app.env` or directly modifying the docker-compose.yml file, as detailed in https://runtipi.io/docs/guides/customize-app-config. + +More info related to available configuration envvars for RSSHub can be found on [https://docs.rsshub.app/deploy/config](https://docs.rsshub.app/deploy/config), however please note that the documentation only contains **some** envvars for configuring a specific app or feature, while a minority of them are poorly-documented or not behaving as according to the official documentation (such as `UA`). In order to get the complete gist of everything, browsing the code at [https://github.com/DIYgod/RSSHub/blob/master/lib/config.ts](https://github.com/DIYgod/RSSHub/blob/master/lib/config.ts) is necessary besides reading the official docs. The given `app.env` file for this app already lists all available variables considering both sources of information and contains the default values specified there, but the **exact** working of any envvar can only be understood by reading the source-code directly after going through the basics at the docs. + +## Access Control + +RSSHub provides an access control feature for restricting which user generates a feed within your instance. This can be enabled with the envvar `ACCESS_KEY`, which can be configured either at the installation step through Runtipi's App Store or via the envvars at `docker-compose.yml` or `app.env` for the RSSHub app. Default value is empty (`""`), which means no extra key is required in order to access a feed through the URLs. + +Note that `ACCESS_KEY` is enabled **globally**, but access can be controlled granularly on an app-by-app basis by only giving the specific app *access code* to a user, as explained through the diagram found on [https://docs.rsshub.app/deploy/config#access-control-configurations](https://docs.rsshub.app/deploy/config#access-control-configurations). + +``` ++ -----------------------------------------------------------------------------------------------------------------+ +| Access key | Route | Generating access code | Access code | +|------------------------------------------------------------------------------------------------------------------| +| ILoveRSSHub | /qdaily/column/59 | md5('/qdaily/column/59' + 'ILoveRSSHub') | 0f820530128805ffc10351f22b5fd121 | ++ -----------------------------------------------------------------------------------------------------------------+ + +* Routes are accessible via code, eg: https://rsshub.app/qdaily/column/59?code=0f820530128805ffc10351f22b5fd121 +* Or using key directly, eg: https://rsshub.app/qdaily/column/59?key=ILoveRSSHub +``` + +## Why self-hosting instead of using a public instance? + +As mentioned before, this app generates a feed for a specific site either using a headless browser or sometimes directly accessing through an API. Some social networks or features, like OpenAI's GPT access requires a valid subscription access token for summarizing posts or other AI-enabled tasks. For social media / content apps that enable some sort of paywall, like X (Twitter), Instagram or Medium, a valid account is necessary in order to generate a feed from "things" happening there. ## Related Projects