rss订阅推送
# Please read https://github.com/Rongronggg9/RSS-to-Telegram-Bot/blob/master/docs/deployment-guide.md for more details.
version: '3.6'
services:
main:
image: lsposed/rss-to-telegram:dev
container_name: telegra_rsstt # need to be unique
volumes:
- ./config:/app/config
environment:
- TOKEN= # get it from @BotFather
- MANAGER= # get it from @userinfobot
# ↓------ To disable sending via Telegraph, comment out this area ------↓ #
# Get Telegraph API access tokens: https://api.telegra.ph/createAccount?short_name=RSStT&author_name=Generated%20by%20RSStT&author_url=https%3A%2F%2Fgithub.com%2FRongronggg9%2FRSS-to-Telegram-Bot
# Refresh the page every time you get a new token.
# If you have a lot of subscriptions, make sure to get at least 5 tokens.
# ↓ Replace with your access tokens ↓
- TELEGRAPH_TOKEN=
b377b0
220216
dac056
3ac268
20d546
# ↑------ To disable sending via Telegraph, comment out this area ------↑ #
# Please read https://github.com/Rongronggg9/RSS-to-Telegram-Bot/blob/master/docs/advanced-settings.md for more details.
# ↓------ Advanced settings ------↓ #
#- MULTIUSER=0 # default: 1
#- CRON_SECOND=30 # 0-59, default: 0
#- DATABASE_URL=postgres://username:password@host:port/db_name # default: sqlite://path/to/config/db.sqlite3
#- API_ID=1025907 # get it from https://core.telegram.org/api/obtaining_api_id
#- API_HASH=452b0359b988148995f22ff0f4229750 # get it from https://core.telegram.org/api/obtaining_api_id
#- IMG_RELAY_SERVER=https://wsrv.nl/?url= # default: https://rsstt-img-relay.rongrong.workers.dev/
#- IMAGES_WESERV_NL=https://t0.nl/ # default: https://wsrv.nl/
#- USER_AGENT=Mozilla/5.0 (Android 12; Mobile; rv:68.0) Gecko/68.0 Firefox/96.0 # default: RSStT/2.2 RSS Reader
#- IPV6_PRIOR=1 # default: 0
#- T_PROXY=socks5://172.17.0.1:1080 # Proxy used to connect to the Telegram API
#- R_PROXY=socks5://172.17.0.1:1080 # Proxy used to fetch feeds
#- PROXY_BYPASS_PRIVATE=1 # default: 0
#- PROXY_BYPASS_DOMAINS=example.com;example.net
#- HTTP_TIMEOUT=30 # default: 12
#- HTTP_CONCURRENCY=0 # default: 1024
#- HTTP_CONCURRENCY_PER_HOST=0 # default: 16
#- TABLE_TO_IMAGE=1 # default: 0
#- TRAFFIC_SAVING=1 # default: 0
#- LAZY_MEDIA_VALIDATION=1 # default: 0
#- MANAGER_PRIVILEGED=1 # default: 0
#- NO_UVLOOP=1 # default: 0
#- MULTIPROCESSING=1 # default: 0
#- DEBUG=1 # debug logging, default: 0
# ↑------ Advanced settings ------↑ #
networks:
- mynetworks
logging:
driver: "json-file"
options:
max-size: "50m"
restart: always
# mem_limit: 100m
# cpus: 0.2
networks:
mynetworks:
external: true
| Key | Description | Example |
|---|---|---|
TOKEN | Your bot token. Get it from @BotFather | 1234567890:A1BCd2EF3gH45IJK6lMN7oPqr8ST9UvWX0Yz0 |
MANAGER | Your Telegram user ID. Get it from @userinfobot | 1234567890 |
| Key | Description | Example | Default |
|---|---|---|---|
API_ID | Your Telegram API ID | 1025907 | (predefined) |
API_HASH | Your Telegram API hash | 452b0359b988148995f22ff0f4229750 | (predefined) |
TELEGRAPH_TOKEN | Telegraph API access token. Get here. 1 | 1a23b456c78de90f1a23b456c78de90f1a23b456c78de90f1a23b456c78d 2 |
| Key | Description | Example | Default |
|---|---|---|---|
T_PROXY | Proxy used to connect to the Telegram API 3 | socks5://172.17.0.1:1080 | |
R_PROXY | Proxy used to fetch feeds 3 | socks5://172.17.0.1:1080 | |
PROXY_BYPASS_PRIVATE | Bypass proxy for private IPs or not? | 1 | 0 |
PROXY_BYPASS_DOMAINS | Bypass proxy for listed domains | example.com;example.net 2 | |
USER_AGENT | User-Agent | Mozilla/5.0 | RSStT/$VERSION RSS Reader |
IPV6_PRIOR | Enforce fetching feeds over IPv6 firstly or not? 4 | 1 | 0 |
TRAFFIC_SAVING | Enable network traffic saving mode or not? 5 | 1 | 0 |
LAZY_MEDIA_VALIDATION | Let Telegram DC to validate media or not? 6 | 1 | 0 |
HTTP_TIMEOUT | HTTP request timeout in seconds | 60 | 12 |
HTTP_CONCURRENCY | HTTP request concurrency overall (0=unlimited) | 0 | 1024 |
HTTP_CONCURRENCY_PER_HOST | HTTP request concurrency per host (0=unlimited) | 0 | 16 |
| Key | Description | Example | Default |
|---|---|---|---|
MULTIUSER | Enable multi-user feature or not? | 0 | 1 |
CRON_SECOND | Run the feed monitoring task at the n-th second of each minute? (0-59) | 30 | 0 |
IMG_RELAY_SERVER | Media relay server URL | https://wsrv.nl/?url= | https://rsstt-img-relay.rongrong.workers.dev/ |
IMAGES_WESERV_NL | https://github.com/weserv/images instance | https://t0.nl/ | https://wsrv.nl/ |
DATABASE_URL | Database URL 7 | postgres://user:[email protected]:5432/table | sqlite://path/to/config/db.sqlite3 |
TABLE_TO_IMAGE | Convert tables to image (causing higher CPU load) or just drop them? | 1 | 0 |
MANAGER_PRIVILEGED | Allow the bot manager to manipulate any users' subscriptions or not? 8 | 1 | 0 |
NO_UVLOOP | Never enable uvloop (even if it is found) or not? | 1 | 0 |
MULTIPROCESSING | Enable multiprocessing (up to min(3, CPU_COUNT)) or not? 9 | 1 | 0 |
DEBUG | Enable debug logging or not? | 1 | 0 |
Manager options are options stored in the database. The bot manager can change it by using the
/set_optioncommand.
| Key | Description | Example | Default |
|---|---|---|---|
default_interval | Default feed monitoring interval 10 | 15 | 10 |
minimal_interval | Minimal feed monitoring interval 11 12 | 10 | 5 |
user_sub_limit | Subscription number limit for ordinary user 13 12 | 150 | -1 (unlimited) |
channel_or_group_sub_limit | Subscription number limit for channel or group 13 12 | 150 | -1 (unlimited) |
sub_limit_reached_message | Additional message attached to the limit reached warning | https://t.me/RSStT_Channel/58 |
————
| 键 | 描述 | 示例 |
|---|---|---|
TOKEN | 您的机器人令牌。从@BotFather获取 | 1234567890:A1BCd2EF3gH45IJK6lMN7oPqr8ST9UvWX0Yz0 |
MANAGER | 您的Telegram用户ID。从@userinfobot获取 | 1234567890 |
| 键 | 描述 | 示例 | 默认值 |
|---|---|---|---|
API_ID | 您的Telegram API ID | 1025907 | (预定义) |
API_HASH | 您的Telegram API哈希 | 452b0359b988148995f22ff0f4229750 | (预定义) |
TELEGRAPH_TOKEN | Telegraph API访问令牌。在此处获取。 1 | 1a23b456c78de90f1a23b456c78de90f1a23b456c78de90f1a23b456c78d 2 |
| 键 | 描述 | 示例 | 默认值 |
|---|---|---|---|
T_PROXY | 用于连接到Telegram API的代理 3 | socks5://172.17.0.1:1080 | |
R_PROXY | 用于获取feeds的代理 3 | socks5://172.17.0.1:1080 | |
PROXY_BYPASS_PRIVATE | 是否为私有IP地址绕过代理? | 1 | 0 |
PROXY_BYPASS_DOMAINS | 绕过代理的域名列表 | example.com;example.net 2 | |
USER_AGENT | 用户代理 | Mozilla/5.0 | RSStT/$VERSION RSS Reader |
IPV6_PRIOR | 是否强制首先使用IPv6获取feeds? 4 | 1 | 0 |
TRAFFIC_SAVING | 是否启用网络流量节省模式? 5 | 1 | 0 |
LAZY_MEDIA_VALIDATION | 是否由Telegram DC验证媒体? 6 | 1 | 0 |
HTTP_TIMEOUT | HTTP请求超时时间(秒) | 60 | 12 |
HTTP_CONCURRENCY | 总体的HTTP请求并发数(0=无限制) | 0 | 1024 |
HTTP_CONCURRENCY_PER_HOST | 每个主机的HTTP请求并发数(0=无限制) | 0 | 16 |
| 键 | 描述 | 示例 | 默认值 |
|---|---|---|---|
MULTIUSER | 是否启用多用户功能? | 0 | 1 |
CRON_SECOND | 在每分钟的第n秒运行feed监控任务?(0-59) | 30 | 0 |
IMG_RELAY_SERVER | 媒体中继服务器URL | https://wsrv.nl/?url= | https://rsstt-img-relay.rongrong.workers.dev/ |
IMAGES_WESERV_NL | https://github.com/weserv/images实例 | https://t0.nl/ | https://wsrv.nl/ |
DATABASE_URL | 数据库URL 7 | postgres://user:[email protected]:5432/table | sqlite://path/to/config/db.sqlite3 |
TABLE_TO_IMAGE | 将表格转换为图片(导致更高的CPU负载)还是丢弃它们? | 1 | 0 |
MANAGER_PRIVILEGED | 是否允许机器人管理员操纵任何用户的订阅? 8 | 1 | 0 |
NO_UVLOOP | 是否永远不启用uvloop(即使找到)? | 1 | 0 |
MULTIPROCESSING | 是否启用多进程(最多min(3, CPU_COUNT))? 9 | 1 | 0 |
DEBUG | 是否启用调试日志? | 1 | 0 |
管理员选项是存储在数据库中的选项。机器人管理员可以使用
/set_option命令更改它。
| 键 | 描述 | 示例 | 默认值 |
|---|---|---|---|
default_interval | 默认的feed监控间隔 10 | 15 | 10 |
minimal_interval | 用户可以为订阅设置的最小监控间隔 11 12 | 10 | 5 |
user_sub_limit | 普通用户的订阅数量限制 13 12 | 150 | -1 (无限制) |
channel_or_group_sub_limit | 频道或群组的订 |
阅数量限制 13 12 | 150 | -1 (无限制) |
| sub_limit_reached_message | 与达到限制的警告附加的额外消息 | https://t.me/RSStT_Channel/58 | |
Refresh the page every time you get a new token. If you have a lot of subscriptions, make sure to get at least 5 tokens. ↩ ↩2
Can be a list, separated by ;, ,, (space), (linebreak), or (tab) ↩ ↩2 ↩3 ↩4
If you would like to use a proxy in a docker container, but your proxy is in your host machine, the hostname should be 172.17.0.1 (Linux) or host.docker.internal (macOS/Windows). Note: your proxy program should also listen to it. ↩ ↩2 ↩3 ↩4
Use with caution. Enabling it will enforce the bot to try to fetch feeds over IPv6 (fallback to IPv4 if failed), which may be helpful if your IPv4 address gets banned by some feed providers. If it is disabled (by default), the bot will still try to fetch feeds over IPv4 and IPv6, but there is no clear priority. You should firstly ensure that the bot has IPv6 connectivity, especially if run in docker. ↩ ↩2
Use with caution. May cause media validating and sending slightly unreliable. Meanwhile, effectively disable webpage title detection for <iframe> tags, instead, the title will always be URL hostname. ↩ ↩2
Use with caution. Help cut down network traffic further. If enabled, RSStT no longer fetches media and validates it. Effectively disable long-pic detection and partially disable icon detection. ↩ ↩2
Ref: https://tortoise-orm.readthedocs.io/en/latest/databases.html. Note that Railway.app will automatically fill this env variable. ↩ ↩2
Use with caution. If enabled, the bot manager can bypass the permission check before manipulating any users'/channels'/groups' subscriptions. The command format is like /sub @username, /sub +9999999999 (ordinary user) or /sub -1009999999999 (channel/group). Should only be used temporarily and be disabled after finishing the manipulation. This option is considered safe for bot users since the bot manager can always manipulate their subscriptions by manipulating the database manually. ↩ ↩2
Only valid when there are more than 1 CPU core, otherwise the process count is always 1. Enabling multiprocessing may help improve the performance on multicore CPUs if there are tons of subscriptions but consumes more memory. If your VPS comes with multiple cores but the performance of each is poor, you may want to enable this feature. ↩ ↩2
After a user subscribes to a feed, the default monitoring interval is applied. ↩ ↩2
The minimal monitoring interval a user can set for a subscription. ↩ ↩2
The bot manager will not be limited by this value. ↩ ↩2 ↩3 ↩4 ↩5 ↩6
Once reached the limit, no more subscriptions can be created. However, existing subscriptions will not be removed even if reaching the limit. As a bot manager, you can enable MANAGER_PRIVILEGED mode to manually unsubscribe their subscriptions. ↩ ↩2 ↩3 ↩4
Content type
Image
Digest
sha256:483f74ea0…
Size
142.5 MB
Last updated
almost 3 years ago
docker pull lsposed/rss-to-telegram