Fediverse with Nextcloud/nginX on Yunohost deel II

The result of part I was being able to find users on the same system. Nice, but not the goal. Over the past weeks I spent some evenings glancing over the problem, hoping to read a post with a nice oneliner as a solution. No such luck.

Today I spent more time than I hoped, but did find part of the solution. The result is now that the webfinger testtool returns a result:



Request log

18:20:13 Looking up WebFinger data for acct:wbk@online.osba.nl
18:20:13 GET https://online.osba.nl/.well-known/webfinger?resource=acct%3Awbk%40online.osba.nl

JSON Resource Descriptor (JRD)

  "subject": "acct:wbk@online.osba.nl",
  "links": [
      "rel": "self",
      "type": "application/activity+json",
      "href": "http://online.osba.nl/nextcloud/nextcloud/index.php/apps/social/@wbk"
      "rel": "http://ostatus.org/schema/1.0/subscribe"

It used to return an error, 404, not found.

More details are at the Yunohost forum, but the important bit is the configuration and where to put it. The config file is the Nginx-configuration at


There are two servers defined, one on port 80 and one on port 443. The first one had a preconfigured redirect, while there was none in the secure section. That was strange, but it didn’t raise any alarms with me. It turns out that the redirect has to be available over TSL as well, and that it has to be a combined redirect/rewrite.

The combined stanza looks like:

location = /.well-known/webfinger {
  rewrite ^ https://online.osba.nl/nextcloud/public.php?service=webfinger&$1 last; # $1 will use the first parameter (?resource=…)

Put this bit between the include-stanza’s and the log-definitions.

Even though the test at webfinger.org succeeds, I have no such succes when contacting this Nextcloud from a Nextcloud on another Yunohost.

To be continued…

Print this entry

2 Replies to “Fediverse with Nextcloud/nginX on Yunohost deel II”

    1. Hi Roboron,

      Thanks for your thoughts on my problem! Sorry for not noticing it any earlier: off-line life took too much time to pay any attention to my blog and only now I noticed a pending reply.

      I just managed to follow @wbk@online.osba.nl from another Yunohost with Nextcloud on it, without changing anything since last time.

      “follow”-actions come through it two directions, even though the other side still says ‘.well-known/webfinger is not configured correctly’.

      The other side is an initial install, with a newer Yunohost and perhaps a nexter Nextcloud.

      Messages don’t come through yet, though. No time to troubleshoot at the moment, tbc as before 😉

      What made you visit this page, if I may ask? Did you have a similar problem, and could you solve it?

Leave a Reply

Your email address will not be published. Required fields are marked *