byeCloud: News with Miniflux

published on in category byeCloud , Tags: byecloud selfhosted caddy docker linux

In this article I will show you how to set up your own RSS feed aggregator with sync support for many third-party clients through the Fever API as a replacement for Apple News/Google News/Feedly. This article is part of the byeCloud series in which I try to replace iCloud with self-hosted services.

Choosing the right software

I fiddled around for a while with the News app for Nextcloud, ttr-rss and a few other alternatives, but ended up with Miniflux (now in version 2) because it is simple and lightweight and provides the most important thing for me, a Fever-compatible API without any plugins. Fever is a self-hosted but closed-source and paid RSS feed aggregator that has integration in quite a few third-party clients. Luckily, Miniflux provides a API that implements the Fever specs, meaning that it can be used with clients that support Fever, in my case this is Reeder for macOS and iOS, probably the best news reader you can get ;-)

System setup

As always in this series, I use Docker in companion with docker-compose to orchestrate the required services. Miniflux in version 2 requires a standalone postgres database to store subscriptions etc.

Here’s an example docker-compose.yml for Miniflux.

version: '3'
services:
  miniflux:
    image: miniflux/miniflux:2.0.5
    links:
      - miniflux-db
    environment:
      DATABASE_URL: "postgres://miniflux:foobar@miniflux-db/miniflux?sslmode=disable"
    ports:
      - 8080:8080

  miniflux-db:
    image: postgres:10.1
    environment:
      POSTGRES_USER: miniflux
      POSTGRES_PASSWORD: foobar
    volumes:
      - miniflux-db-data:/var/lib/postgresql/data

  volumes:
    miniflux-db-data:

You might also want to put a reverse-proxy in front like Caddy, nginx or Traefik as this will also give you HTTPS with certificates from Let’s Encrypt.

After running docker-compose up -d, Miniflux will start but does not work yet. Yes I know, this is not how Docker containers should work but anyway… you have to run the following commands to migrate the database schema manually and create a administrator user, as you can read here:

docker-compose exec miniflux /usr/local/bin/miniflux -migrate
docker-compose exec miniflux /usr/local/bin/miniflux -create-admin

Afterwards you can go to yoursite:8080 and log in with your admin login.

You also might have noticed that I pinned the image version, this is not by accident: Miniflux does not offer a latest tag that would allow you to run on a rolling release. So when a new version is released, remember to update your image version and runn the migrate command after recreating the container.

Configuration

Then go to “Settings” -> “Integrations” and enable the Fever API, provide username and password.

Miniflux Fever API

Client side: macOS

On macOS I use Reeder as my news reader of choice after trying many others and I’ve never thought about changing again. Though this is not open source and not free, it proved to be the best solution I could imagine. I bought it on the Mac App Store. Then just add your Fever API connection in the preferences and it will sync.

reeder_account_mac

Reeder on macOS with Miniflux/Fever API

Client side: iOS

On iOS I use Reeder as well. Same arguments as for macOS ;-). I bought it on the App Store. Setup works the same way like on macOS.

reeder-ios

Data migration

As I did not have any other news reader before, there was nothing to migrate. But many news reader services offer you to export your subscriptions as a OPML file. Miniflux can import this, so this should be enough to migrate your subscriptions.

Pitfalls

To subscribe to a new feed, you need to log in to the Miniflux web UI and add the subscription there. It’s not possible to do this from within Reeder directly.

Thanks

As always in this series, I’m using free and open-source software. I’m sure the developers of Miniflux would also be happy if you consider donating them a few coins to keep their great work up!