[OSGeo] #3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+-----------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Keywords:
-------------------------------+-----------------------
Searching for strk@video.osgeo.org on a mastodon instance yeld no results
but an error {{{ 503 Remote data could not be fetched }}}

But you can find jsanz@video.osgeo.org or foss4g@video.osgeo.org just fine

Logs contain this:
{{{
2023/11/24 20:53:31 [error] 494#494: *69168 connect() failed (111:
Connection refused) while connecting to upstream, client: 57.128.95.182,
server: video.osgeo.org, request: "GET /.well-
known/webfinger?resource=acct:strk@video.osgeo.org HTTP/1.0", upstream:
"http://[::1]:9000/.well-
known/webfinger?resource=acct:strk@video.osgeo.org", host:
"video.osgeo.org"
}}}

But similar log entries exist for aryang257@video.osgeo.org who can also
be found just fine from Mastodon, so I don't know what's going on exactly.
--
Ticket URL: <https://trac.osgeo.org/osgeo/ticket/3036&gt;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

See also #3035
--
Ticket URL: <https://trac.osgeo.org/osgeo/ticket/3036#comment:1&gt;
OSGeo <https://osgeo.org/&gt;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

The change in https://trac.osgeo.org/osgeo/ticket/3035#comment:2 did not
change my experience with the {{{ 503 Remote data could not be fetched }}}
issue.

The webfinger for {{{ strk@video.osgeo.org }}} can be checked for example
with this generic client:
https://webfinger.net/lookup/?resource=strk%40video.osgeo.org

At this very moment the webfinger returned is:
{{{
{
   "subject": "acct:strk@video.osgeo.org",
   "aliases": [
     "https://videos.osgeo.org/accounts/strk&quot;
   ],
   "links": [
     {
       "rel": "self",
       "type": "application/activity+json",
       "href": "https://videos.osgeo.org/accounts/strk&quot;
     },
     {
       "rel": "http://ostatus.org/schema/1.0/subscribe&quot;,
       "template": "https://video.osgeo.org/remote-interaction?uri=\{uri\}&quot;
     }
   ]
}
}}}

The webfinger for jsanz is pretty much the same:

{{{
{
   "subject": "acct:jsanz@video.osgeo.org",
   "aliases": [
     "https://video.osgeo.org/accounts/jsanz&quot;
   ],
   "links": [
     {
       "rel": "self",
       "type": "application/activity+json",
       "href": "https://video.osgeo.org/accounts/jsanz&quot;
     },
     {
       "rel": "http://ostatus.org/schema/1.0/subscribe&quot;,
       "template": "https://video.osgeo.org/remote-interaction?uri=\{uri\}&quot;
     }
   ]
}
}}}

So I think that part (webfinger) works.

This then becomes a difference beween:

  - https://videos.osgeo.org/accounts/strk
  - https://videos.osgeo.org/accounts/jsanz

Unfortunately I don't get any result by searching the above URIs. Could be
a Mastdon issue, will take a look
--
Ticket URL: <https://trac.osgeo.org/osgeo/ticket/3036#comment:2&gt;
OSGeo <https://osgeo.org/&gt;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by robe):

> So I think that part (webfinger) works.
>
> This then becomes a difference beween:
>
> - https://videos.osgeo.org/accounts/strk
> - https://videos.osgeo.org/accounts/jsanz
>
> Unfortunately I don't get any result by searching the above URIs. Could
be a Mastdon issue, will take a look

Just checking you know you've got a typo there, it's video.osgeo.org not
videos.osgeo.org. Remember that was your idea :slight_smile:

- https://video.osgeo.org/accounts/strk
- https://video.osgeo.org/accounts/jsanz
--
Ticket URL: <https://trac.osgeo.org/osgeo/ticket/3036#comment:3&gt;
OSGeo <https://osgeo.org/&gt;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by robe):

I did a compare of strk and jsanz account and noticed that

jsanz profile has a checkbox checked

User bypasses video validation by moderators
Enable this checkbox if this user doesn't need to have its videos reviewed
by moderators.

Where as strk account did not have that box checked. strk I just ticked
that box on your account. See if that fixes your issue.
--
Ticket URL: <https://trac.osgeo.org/osgeo/ticket/3036#comment:4&gt;
OSGeo <https://osgeo.org/&gt;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

A possible source of bugs with federation of the OSGeo PeerTube instance
was suggested in this post:
https://framapiaf.org/@Chocobozzz/111527409253398290
--
Ticket URL: <https://trac.osgeo.org/osgeo/ticket/3036#comment:5&gt;
OSGeo <https://osgeo.org/&gt;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

> it's video.osgeo.org not videos.osgeo.org. Remember that was your idea
:slight_smile:

Note that I search for "strk@video.osgeo.org" (with no final "s") but the
webfinger service replies with an URI with the "s" in "videos", see:

     WebFinger

I think that's one of the problems
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

A search for "​strk@video.osgeo.org" on mapstodon.space still yelds no
results.
I suspect somehow mapstodon.space got to know jsanz@video.osgeo.org in
some other way because that account I do can find.
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

One difference between my peertube account and jsanz' is that he got a
follower and I don't, maybe that's also related somehow
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

Ah but now I see the webfinger between jsanz and me is different: only
mine points to videos.osgeo.org (with the s) while jsanz does not ! Why
this happened I've no idea but looks like the probably source of trouble.
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by robe):

Mine seems to have the same issue
WebFinger

Maybe we had logged in before I switched the domain to video.osgeo.org and
that is now stuck now in space somewhere.
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: new
Priority: normal | Milestone: Unplanned
Component: SysAdmin/Peertube | Resolution:
Keywords: |
-------------------------------+------------------------
Comment (by strk):

I've taken a look at the PostgreSQL backend database and found there are
many references to videos.osgeo.org in the "actor" table which are very
likely the source of this problem. Possible fixes are:

  1. Make videos.osgeo.org redirect to video.osgeo.org
  2. Update the database to replace videos.osgeo.org with video.osgeo.org

Option 1 will ALSO work for such references present on foreign databases
(in case some ActivityPub actor from a foreign server ever "followed" the
old names); unlikely BUT we probably have NO WAY to tell, other than re-
add a DNS record for that name and log HTTP requests there.
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+---------------------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: closed
Priority: normal | Milestone: Sysadmin Contract 2024-I
Component: SysAdmin/Peertube | Resolution: fixed
Keywords: |
-------------------------------+---------------------------------------
Changes (by robe):

* status: new => closed
* resolution: => fixed
* milestone: Unplanned => Sysadmin Contract 2024-I

Comment:

Okay I did this update in the db and seems to have fixed our webfingers

{{{
su postgres
psql -d peertube_prod

-- in psql
UPDATE actor SET "outboxUrl" = replace("outboxUrl", 'videos.osgeo.org',
'video.osgeo.org'), "inboxUrl" = replace("inboxUrl", 'videos.osgeo.org',
'video.osgeo.org') WHERE "outboxUrl" LIKE '%videos.osgeo.org%';

UPDATE actor SET "url" = replace("url", 'videos.osgeo.org',
'video.osgeo.org')
         , "sharedInboxUrl" = replace("sharedInboxUrl", 'videos.osgeo.org',
'video.osgeo.org')
         , "followersUrl" = replace("followersUrl", 'videos.osgeo.org',
'video.osgeo.org')
         , "followingUrl" = replace("followingUrl", 'videos.osgeo.org',
'video.osgeo.org')
         WHERE "url" LIKE '%videos.osgeo.org%';

UPDATE "actorFollow" SET url = replace(url, 'videos.osgeo.org',
'video.osgeo.org') WHERE url LIKE '%videos.osgeo.org%';

}}}

It updated 9 records of which two were ours.

I confirm I can now follow robe@video.osgeo.org on my mapstodon account
where as I couldn't before.
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+---------------------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: closed
Priority: normal | Milestone: Sysadmin Contract 2024-I
Component: SysAdmin/Peertube | Resolution: fixed
Keywords: |
-------------------------------+---------------------------------------
Comment (by strk):

I confirm I can now find my peertube account, but I'm having other
problems with finding videos from mastodon, did you have a read at
CLI tools guide | PeerTube documentation
domain-name ?
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+---------------------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: closed
Priority: normal | Milestone: Sysadmin Contract 2024-I
Component: SysAdmin/Peertube | Resolution: fixed
Keywords: |
-------------------------------+---------------------------------------
Comment (by neteler):

Replying to [comment:3 robe]:
> Just checking you know you've got a typo there, it's video.osgeo.org not
videos.osgeo.org. Remember that was your idea :slight_smile:

Silly proposal: have videos.osgeo.org as a DNS alias? This kind of typo-
creeping-in will continue for sure... (IMHO video.osgeo.org is pretty
counter-intuitive).
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.

#3036: Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not
be fetched
-------------------------------+---------------------------------------
Reporter: strk | Owner: sac@…
     Type: task | Status: closed
Priority: normal | Milestone: Sysadmin Contract 2024-I
Component: SysAdmin/Peertube | Resolution: fixed
Keywords: |
-------------------------------+---------------------------------------
Comment (by strk):

I don't think the idea is silly, but the SSL certificates will only be
valid for one or the other so it cannot be an alias but can be a redirect,
which is what I already proposed and was considered overkill for a service
which honestly was just born when we switched names. What is it that you
find counter-intuitive ? It matches with "trac" and "git" and "www" and
"discourse" none of which is plural
--
Ticket URL: <#3036 (Mastodon search for strk@video.osgeo.org yelds: 503 Remote data could not be fetched) – OSGeo;
OSGeo <Gter - OSGeo;
OSGeo committee and general foundation issue tracker.