Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhancement: Add storage quota #54

Open
Forceu opened this issue Apr 11, 2022 · 3 comments
Open

Enhancement: Add storage quota #54

Forceu opened this issue Apr 11, 2022 · 3 comments
Labels
enhancement New feature or request

Comments

@Forceu
Copy link
Owner

Forceu commented Apr 11, 2022

No description provided.

@Forceu Forceu added the enhancement New feature or request label Apr 11, 2022
@MalteMagnussen
Copy link

If using S3, you can add a quota to the Bucket, and get this feature that way

That makes me think; Is there an Error message in the app, if the Bucket is full btw?

We set up a policy on the bucket to delete any file older than 30 days, but it might fill up anyway.

Would the users be notified that the uploads fails, because the bucket is full?

@Forceu
Copy link
Owner Author

Forceu commented May 27, 2024

If the upload fails, an error will be displayed. How are you setting the quota? And is there an API to retrieve the remaining space?

@MalteMagnussen
Copy link

MalteMagnussen commented May 28, 2024

We set up a policy on the bucket to delete any file older than 30 days, but it might fill up anyway.

Via the aws cli you can set the policies:

$ aws s3api put-bucket-lifecycle-configuration help

$ aws s3api put-bucket-lifecycle-configuration --bucket your_bucket_name --endpoint-url https://your.s3.instance --lifecycle-configuration '{
  "Rules": [
    {
      "ID": "Delete old objects",
      "Status": "Enabled",
      "Filter": {},
      "Expiration": {
        "Days": 30
      }
    }
  ]
}'

$ aws s3api get-bucket-lifecycle-configuration --bucket your_bucket_name
{
    "Rules": [
        {
            "Expiration": {
                "Days": 30
            },
            "ID": "Delete old objects",
            "Filter": {},
            "Status": "Enabled"
        }
    ]
}

How are you setting the quota? And is there an API to retrieve the remaining space?

To check the remaining space, I personally just check our S3 website.

And to set the quota, I also just used the website.

Thanks for confirming the error display :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants