YunoHost-Apps / nextcloud_ynh

Nextcloud package for YunoHost
https://nextcloud.com/
GNU Affero General Public License v3.0
147 stars 63 forks source link

Add trashbin cleanup and file versioning #612

Open tio-trom opened 11 months ago

tio-trom commented 11 months ago
  'trashbin_retention_obligation' => 'auto, 30',
  'versions_retention_obligation' => 'auto, 30',

To the config file. This way we make sure that after 30 days the trashbin gets cleaned up. Also only keep file versioning for 30 days. I think it makes sense, else the server will fill up with trashed files and infinite number of file versioning.

Bugsbane commented 11 months ago

Clearing the trashbin certainly makes sense as the user has specifically chosen to delete items and then not restored them for a month. I would be hesitant to set versions to 30 days though, as this could be an unexpected behavior to users leading to data loss.

We don't want old versions filling up the server though, but I would suggest that this would be better served by setting it to not delete automatically by default, but suggesting this config setting in the Yunohost app description and app docs so server admins will be aware if it is set.

tio-trom commented 11 months ago

The file versioning means to only keep 30 versions of the same file. I think that's also reasonable.

Bugsbane commented 11 months ago

Ah, ok. My mistake. I didn't read closely enough assumed it was also 30 days. In that case yes, both make good sense.

Tagadda commented 11 months ago

I don't think the default behavior is good for most use cases. We could handle file retention through the config panel tho'

lapineige commented 11 months ago

Yeah as user won't be able to notice the change that easily, I would be more in favour of a min 30 days of retention + delete only if space needed, which serves the purpose of freeing space when it grows too much, but keep a safe month of trashbin history.

Tagadda commented 11 months ago

Make admins notice the change easily, that's a mission for POST_UPGRADE.md o/