+++ title = "El Monitorro" sort_by = "weight" +++
El Monitorro
El Monitorro is RSS, Atom and JSON feed reader as a Telegram bot.
It's available at @el_monitorro_bot.
/start - show the bot's description and contact information /subscribe url - subscribe to feed /unsubscribe url - unsubscribe from feed /list_subscriptions - list your subscriptions /help - show available commands /set_timezone - set your timezone. All received dates will be converted to this timezone. It should be offset in minutes from UTC. For example, if you live in UTC +10 timezone, offset is equal to 600 /get_timezone - get your timezone /set_template url template - set a template for all received items for the specified subscription. All new updates will be converted to the format defined by this subscription. Supported fields you can use for templates: - bot_feed_name - name of the feed - bot_feed_link - url of the feed - bot_item_name - name of the item - bot_item_link - url of the item - bot_item_description - description of the item - bot_date - publication date of the feed Example: /set_template https://www.badykov.com/feed.xml {{bot_feed_name}} {{bot_item_name}} {{bot_date}} {{bot_item_link}} Also, there is `substring` helper that can be used to limit the number of characters. For example, {{substring bot_item_description 100}} /get_template url - get a template for the subscription /remove_template url - remove the template /set_global_template - set global template. This template will be used for all subscriptions. If the subscription has its own template, the subscription template will be used. See /set_template for available fields. /remove_global_template - remove global template /get_global_template - get global template /get_filter url - get a filter for the subscription /set_filter url filter - set filter, for example, /set_filter https://www.badykov.com/feed.xml telegram,bots. You'll start receiving posts only containing words in the filter. Use `!word` to stop receiving messages containing the specified `word`. You can combine regular filter words with ! filter words. For example, `!bot,telegram` /remove_filter url - remove filter /set_global_filter filter - set global filter /get_global_filter - get a global filter /remove_global_filter - remove global filter /info - shows the number of subscriptions and chats. it's available only for the admin (`ADMIN_TELEGRAM_ID`) /set_content_fields url fields - changes content hash fields of the specified feed. it's available only for the admin (`ADMIN_TELEGRAM_ID`). Example: /set_content_fields https://www.badykov.com/feed.xml author,title By default content hash is calculated from title and url. Available fields: - link - title - publication_date - guid - description - author
el_monitorro
by:DATABASE_URL
) and telegram bot token (TELEGRAM_BOT_TOKEN
) to .env
file in the root directory. For example:DATABASE_URL=postgres://admin:pass@localhost/el_monitorro TELEGRAM_BOT_TOKEN=MYTOKEN
diesel database setup
RUST_LOG=info RUST_BACKTRACE=1 cargo run --bin el_monitorro
RUST_LOG=info RUST_BACKTRACE=1 cargo run --bin sync
RUST_LOG=info RUST_BACKTRACE=1 cargo run --bin deliver
RUST_LOG=info RUST_BACKTRACE=1 cargo run --bin cleaner
/subscribe@handle
along with just /subscribe
DELIVER_INTERVAL_SECONDS
secondsCLEAN_INTERVAL_SECONDS
seconds/info
command with stats is available for ADMIN_TELEGRAM_IDSETUP_DB
- if this variable is not empty, diesel database setup
is run. It creates DB and runs migrations.RUN_MIGRATION
- if this variable is not empty, diesel migration run
is run. It just runs migrations.BOT_BINARY
- depending on this variable, docker container will run one of four binaries. Possible values are commands
, sync
, deliver
, cleaner
. To run all services in the main binary, set:RUN_MIGRATION=true BOT_BINARY=commands ALL_BINARIES=true
docker run --env-file ./.env --network host -t ayratbadykov/el_monitorro:latest
-network host
is used so the docker container can access a host network if you're running Postgres on the same machine