Skip to content

allow admin to configure the max trashbin size - #21658

Merged
MorrisJobke merged 1 commit into
masterfrom
trashbin-configurable-size
Jul 21, 2020
Merged

allow admin to configure the max trashbin size#21658
MorrisJobke merged 1 commit into
masterfrom
trashbin-configurable-size

Conversation

@icewind1991

Copy link
Copy Markdown
Member

this allows an admin to configure the max trashbin size instead of always relying on the users quota.

The trashbin size can be configured using the occ trash:size command and can be set both globally and per-user

Signed-off-by: Robin Appelman robin@icewind.nl

@icewind1991icewind1991 added the 3. to review Waiting for reviews label Jul 2, 2020
@icewind1991icewind1991 added this to the Nextcloud 20 milestone Jul 2, 2020

@ChristophWurstChristophWurst left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks fine

Comment threadapps/files_trashbin/lib/Command/Size.php Outdated
Comment threadapps/files_trashbin/lib/Command/Size.php Outdated
@MorrisJobkeMorrisJobke added 2. developing Work in progress and removed 3. to review Waiting for reviews labels Jul 6, 2020
@icewind1991
icewind1991force-pushed the trashbin-configurable-size branch from 1a29e1d to 02dede4CompareJuly 7, 2020 12:39
@icewind1991icewind1991 added 3. to review Waiting for reviews and removed 2. developing Work in progress labels Jul 7, 2020
@icewind1991

Copy link
Copy Markdown
MemberAuthor

done

this allows an admin to configure the max trashbin size instead of always relying on the users quota.
The trashbin size can be configured using the `occ trash:size` command and can be set both globally and per-user
Signed-off-by: Robin Appelman <robin@icewind.nl>
@icewind1991
icewind1991force-pushed the trashbin-configurable-size branch from 02dede4 to 050e2feCompareJuly 7, 2020 12:45

@MorrisJobkeMorrisJobke left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks good 👍

@MorrisJobke
MorrisJobke merged commit 7b250db into masterJul 21, 2020
@MorrisJobke
MorrisJobke deleted the trashbin-configurable-size branch July 21, 2020 18:46
@icewind1991

Copy link
Copy Markdown
MemberAuthor

/backport to stable19

@icewind1991

Copy link
Copy Markdown
MemberAuthor

/backport to stable18

@GAS85

GAS85 commented Sep 14, 2020

Copy link
Copy Markdown

I suppose command should be occ trashbin:size, not occ trash:size. Reference https://docs.nextcloud.com/server/19/admin_manual/configuration_server/occ_command.html#trashbin

@MorrisJobke

Copy link
Copy Markdown
Member

The trashbin size can be configured using the occ trash:size command and can be set both globally and per-user

That's just a typo I guess.

The code says so as well: https://github.com/nextcloud/server/pull/21658/files#diff-4deaa41582a337ef216fd10850de68b4R56

@GAS85

Copy link
Copy Markdown

When it will be documented?

@MorrisJobke

Copy link
Copy Markdown
Member

@GAS85 Mind to add it to the documentation repository issue tracker or directly edit the documentation page and add it there? That would help a lot and we can review and include it.

@GAS85

Copy link
Copy Markdown

@MorrisJobke glad to do it, but syntax is not clear to me, e.g.

trashbin:size [--output [OUTPUT]] [-u|--user USER] [--] [<size>]

User and Size are clear, but what is output?
Also size in %? How to put unlimited? From the code seems via negative value, but I'm not sure here 😞

@GAS85

Copy link
Copy Markdown

Any update here?
Was "playing" with settings to understand it and drop the hole limits to 0 that deletes all users trashin content...
So please, write the documentation:

  • explain how to set e.g. 50% of quote.
  • how to set for all users
  • how to set absolute e.g. in GB, KB, MB...

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to reviewWaiting for reviews

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@icewind1991@GAS85@MorrisJobke@ChristophWurst