Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/evroon/selfoss-discord
Send RSS updates from Selfoss to Discord
https://github.com/evroon/selfoss-discord
discord rss rust
Last synced: 27 days ago
JSON representation
Send RSS updates from Selfoss to Discord
- Host: GitHub
- URL: https://github.com/evroon/selfoss-discord
- Owner: evroon
- Created: 2021-05-22T22:35:41.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2024-03-25T05:57:03.000Z (10 months ago)
- Last Synced: 2024-10-27T13:21:00.946Z (3 months ago)
- Topics: discord, rss, rust
- Language: Rust
- Homepage:
- Size: 84 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# selfoss-discord
[![build](https://github.com/evroon/selfoss-discord/actions/workflows/build.yaml/badge.svg)](https://github.com/evroon/selfoss-discord/actions/workflows/build.yaml)
[![codecov](https://codecov.io/gh/evroon/selfoss-discord/graph/badge.svg?token=626FVGQH49)](https://codecov.io/gh/evroon/selfoss-discord)Send RSS updates from Selfoss to Discord.
The Python script fetches new RSS items from `/items` and sends a message to discord for each new RSS item. The messages are sent in specific Discord channels that are created based on the RSS feed's name.
Preview of an RSS update message in Discord: (using [msfs-rss](https://github.com/evroon/msfs-rss))
![Preview](https://raw.githubusercontent.com/evroon/selfoss-discord/main/etc/preview.png)
## Usage
First, install openssl:
```
sudo apt-get install pkg-config libssl-dev
```Create a bot in Discord with permissions to send manages and manage channels for the server you want to send messages to.
Create a file called `.env` with the following content:
```bash
DISCORD_TOKEN="your discord bot token"
DISCORD_SERVER_ID="the ID of your server/guild"
SELFOSS_BASE_URL="url where selfoss lives"
SELFOSS_USERNAME="selfoss username"
SELFOSS_PASSWORD="selfoss password"
```Use systemd to run the update periodically, like this [service](https://github.com/evroon/concordia/blob/master/ansible/roles/selfoss/templates/selfoss-update.service.j2) and [timer](https://github.com/evroon/concordia/blob/master/ansible/roles/selfoss/templates/selfoss-update.timer.j2).