Can't upload file via XMPP server

Hello,

What is the correct way to have uploading working out of the box with Yunohost ?
I have read many docs but still it fails.

Here is my config: https://paste.yunohost.org/arivawuhit

Thanks for your help

N.B: is prosody still in the pipe ?

I think you might want to read this thread : Images upload with XMPP / Metronome and https://github.com/YunoHost/issues/issues/1278 (bottom line is : currently it’s probably broken and help is welcome to provide a fix)

I think currently the status quo is “since metronome is now maintained again. the cost vs. interest of migrating to prosody is not so interesting for now…”

Ok, reading all your pointers leaded nowhere, sadly. I could find a solution by browsing deeply in the Metronome issue tracker and documentation.

What I have worked is by setting it like this:

Host "*"
       interfaces = { "*" }
       ssl = { key = "/etc/yunohost/certs/upload.maillard.im/key.pem", certificate = "/etc/yunohost/certs/upload.maillard.im/crt.pem" }
      http_ports = {}
      https_ports = { 5290 }

Obviously, XMPP clients would refuse to upload without HTTPS and thus, yunohost should not mention it.

2 Likes

But I see you have a certificate for upload.yourdomain.tld so somehow did you add upload.yourdomain.tld as a yunohost domain and fetch the Lets Encrypt certificate ?

Exactly. The complete recipe to have this working is:

  1. have a DNS entry as a CNAME (or a wildcard redirection for it)
  2. declare it as a domain in the yunohost admin panel
  3. get a LE certificate
  4. declare it in the metronome config as stated below

Regards

1 Like

Still not really a long-term solution to fix it in YunoHost then, we can’t just ask people to add upload.domain.tld as a yunohost domain if they want to just use the feature :s

But okay, probably some tweak can be found to work with the certificate for domain.tld or something.

Maybe it could be done automagically on install without user intervention. I’d rather wannt to see jingle used instead of the HTTP upload mechanism but as always that’s another story.

What’s jingle ?

It is an XMPP extension (XEP-0166) which is, among others, an alternative of the HTTP upload (more in the XMPP way)

https://xmpp.org/extensions/xep-0166.html