yunohost
yunohost copied to clipboard
[xmpp] setup http_upload_external
The problem
http upload is currently managed by metronome, but it's a deprecated part of metronome which has a limited mime types handling (For example pdf or doc file are not in the default handled mime types).
http upload is not the responsibility of metronome and need to be outsource.
Solution
use the external http upload way describe on metronome documentation.
PR Status
PENDING check/test/approval
How to test
- Try to send a pdf file,
- confirm the transfer failure
- apply the patch
- regenerate configurations for metronome and nginx
- try to send again a pdf and other kinds of files
- see the success .. or not !
@maranda finally we may have external http upload @pitchum here the PR for you to test :) Let me know what piece of code if any are not at the correct locations.
maybe we can add add_header Content-Security-Policy "default-src 'none'; frame-ancestors 'none';";
as advised in https://xmpp.org/extensions/xep-0363.html#server pointed by @randomstuff
We should backup and restore the xmpp-upload dir and the secret you added.
We should backup and restore the xmpp-upload dir and the secret you added.
Do we really want to backup the xmpp-upload folder ? if we spawn a new instance somewhere else, metronome will not keep track of the files, and they will stay forever in the folder ...
I suggest to use this perl implementation instead https://github.com/weiss/ngx_http_upload . No new dependencies, no daemon to run.
There is also a flask implementation: https://github.com/horazont/xmpp-http-upload
In any case, Metronome should be a yunohost app, cause a lot of server don't use it.
Closing because it's been 2 years and the plan is more to go towards metronome-as-an-app rather than handling all its complexity from YunoHost core ...