YunoHost-Apps / synapse_ynh

Matrix server (synapse) package for YunoHost
https://matrix.org/
GNU General Public License v3.0
79 stars 42 forks source link

[Feature] Store media in yunohost user home/nextcloud folder #282

Open Gredin67 opened 3 years ago

Gredin67 commented 3 years ago

Synapse data can be huge. So are the backups of the app. In homeserver.yaml it is possible to set custom path to store media.

We could add an option to store media data in the home folder of the corresponding Yunohost user. Even better, the media could be reached directly in Nextcloud in a given folder. I know that Nextcloud data are either stored in home or in specific folder, depending on an install parameter.

lapineige commented 3 years ago

Don't you need to use nextcloud-cli to sync the changes in that case ? :thinking:

Josue-T commented 3 years ago

Data are already stored in /home/yunohost.app/matrix-synapse

Gredin67 commented 3 years ago

I meant would there be a way to store the Matrix media of a SSO/Yunohost user in his home folder ~, and even better in some sub-folder of his Nextcloud folder. The idea would be that media generated by his synapse chats would be considered in his storage quota. I don't have a clue how Yunohost user data are stored, thus my idea may not make sense.

MayeulC commented 3 years ago

Interesting feature request, this makes sense to me.

Maybe you could use an external media repository like https://matrix.org/docs/projects/other/matrix-media-repo (https://github.com/turt2live/matrix-media-repo)

I don't think this is a feature of that repository, so you could open a feature request there :)

jchammons commented 2 years ago

I have also come across the following article:

It makes mention of some potential things changing upstream:

I would think that a lot of what could be done to clean up is outside the scope of what the synapse_ynh package is intended for, however. Just my two cents.

MayeulC commented 2 years ago

Actually matrix-media-repo seems to support quotas, so it would need to be wired up with yunohost's quota system.

https://github.com/turt2live/matrix-media-repo/issues/100 -> https://github.com/turt2live/matrix-media-repo/commit/eb625dd968a34579559faf51a50b4f0f90b21ecf

Gredin67 commented 2 years ago

is there a label like "looking for help"? This feature would be great!

Gredin67 commented 1 year ago

@Thatoo is working on a nice workaround based on https://gitlab.com/Sorunome/matrix-nextcloud-integration and https://github.com/gary-kim/riotchat/pull/369/files

He might build a yunohost package out of it, or it may make sense to integrate some things in the synapse_ynh package. Wait and see..