Auto-delete old file/mail

good morning

I have version v0.26c in production which I am preparing to update.

I should however remove the superfluous and since there are hundreds of mailboxes, I should therefore automate the process. I would like to delete:

  • Mail in the trash folder older than 90 days
  • Mail in the spam folder older than 90 days
  • Files in the nextcloud trash folder older than 90 days

Is there any solution?

Thank you

Be sure that you find the threads that discuss this in detail. You are going to be in a world of hurt if you do not. I hope that you at least ran sudo apt upgrade before Ubuntu went EoL in April 2018. If you did not - I am going to suggest to you that you follow a complete different path.

The system is completely virtual, the operating system works on a “disk” separate from the data.
There is no need to worry from that point of view.
So I’ll do an installation of the new MIB on a new virtual one and then move the data.
I want to avoid bringing garbage into the new version.
So implement a policy like the one shown in the question above.

Yes, should work perfectly. Just be certain to run sudo mailinabox to update the data to the current version of NC - this will be handled splendidly by MiaB.

Hmm, I answered your question a couple of days ago – in another thread.