Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/joonas-fi/rss-to-homeassistant
Pushes RSS feeds into Home Assistant as Markdown, so they can be displayed natively.
https://github.com/joonas-fi/rss-to-homeassistant
home-assistant home-automation markdown rss rss-feed
Last synced: about 1 month ago
JSON representation
Pushes RSS feeds into Home Assistant as Markdown, so they can be displayed natively.
- Host: GitHub
- URL: https://github.com/joonas-fi/rss-to-homeassistant
- Owner: joonas-fi
- License: apache-2.0
- Created: 2021-03-22T08:07:41.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-07-09T10:35:25.000Z (4 months ago)
- Last Synced: 2024-10-01T05:20:57.069Z (about 2 months ago)
- Topics: home-assistant, home-automation, markdown, rss, rss-feed
- Language: Go
- Homepage: https://joonas.fi/2020/08/displaying-rss-feed-with-home-assistant/
- Size: 181 KB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Security: docs/security.md
Awesome Lists containing this project
README
⬆️ For table of contents, click the above icon
![Build status](https://github.com/joonas-fi/rss-to-homeassistant/workflows/Build/badge.svg)
[![Download](https://img.shields.io/github/downloads/joonas-fi/rss-to-homeassistant/total.svg?style=for-the-badge)](https://github.com/joonas-fi/rss-to-homeassistant/releases)Pushes RSS feeds into Home Assistant as Markdown, so they can be displayed natively.
For more background, see my [blog post](https://joonas.fi/2020/08/displaying-rss-feed-with-home-assistant/).
Prerequisites
-------------- Home Assistant
- Home Assistant needs to be connected to a MQTT server
- This softwareConfiguration
-------------You need to create `config.json`:
```json
{
"mqtt": {
"address": "127.0.0.1:1883",
"credentials": {
"username": "AzureDiamond",
"password": "hunter2"
}
},
"rss_feeds": [
{
"id": "skrolli",
"url": "https://skrolli.fi/feed/"
}
]
}
```If you don't use MQTT username/password, you can remove the whole `"credentials": {...}` section.
How to use
----------You can run this on any computer as long as it can connect to the same MQTT server that Home Assistant uses.
For example, make a directory `/home//rss-to-homeassistant`.
Download a suitable binary there (for Raspberry Pi, use the ARM build, for PCs use the amd64 build).
You can rename the downloaded binary to `rss-to-homeassistant`.
You've created the configuration file. The directory has these contents:
```
/home/pi/rss-to-homeassistant
├── config.json
└── rss-to-homeassistant
```Test starting it manually. If everything goes well, you should see this message:
```console
$ ./rss-to-homeassistant
2021/03/22 07:45:30 [INFO] skrolli changed
```You can stop it with `Ctrl + c`.
The RSS feed should've just popped into Home Assistant (because we use its
[autodiscovery](https://www.home-assistant.io/docs/mqtt/discovery/) mechanism to advertise the feeds):![](docs/home-assistant-entity.png)
This means that Home Assistant has the Markdown content of the RSS feed. We're close to the finish line.
Displaying the feed's Markdown content
--------------------------------------You need to add a Markdown card, with content that has a dynamic placeholder to display the feed
entity's Markdown content:![](docs/home-assistant-markdown-card.png)
You're done!
Keep this running across system restarts
----------------------------------------If you're on Linux, we have a helper to integrate with systemd:
```console
./rss-to-homeassistant install-as-service
Wrote unit file to /etc/systemd/system/rss-to-homeassistant.service
Run to enable on boot & to start (--)now:
$ systemctl enable --now rss-to-homeassistant
Verify successful start:
$ systemctl status rss-to-homeassistant
```If you followed the tips the installer gave, this program should automatically start after reboots.
Have fun! Enjoy life.TODO
----- Consider polling interval, 1 minute might be too often
- Implement HTTP caching to be nice to RSS publishers