Storage bucked INSERT filtering with mimetype #1538
Unanswered
TheBlueOompaLoompa
asked this question in
Questions
Replies: 1 comment
-
Hi @TheBlueOompaLoompa, are you looking for a way to have an allowlist of mimetypes for the entire bucket? Currently adding policies based on metadata for INSERTs is not supported. This is because we find out the metadata of the object (like size and mimetype) only after the object is uploaded since we directly stream the request to s3. This is why policies for INSERT based on size is not supported as well.
For now you might have to add the check on the client side or check the mimetype after the upload operation has finished. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have a storage bucket that I want to only take files with the mime type that contains image.
Here is my attempt:
((metadata ->> 'mimetype'::text) ~ 'image'::text)
Beta Was this translation helpful? Give feedback.
All reactions