Issues filed here should be about a feature request for a specific extension in this repository. To file a feature request that affects multiple extensions or the Firebase Extensions platform, please reach out to
Firebase support directly.
This feature request is for extension: storage-resize-images
It would be great to have the possibility to define a list of absolute paths inside the bucket in which listen for new image uploads to be resized.
The absolute paths to be provided in the configuration option could be a comma-separated list, like this:
/users/avatars,/posts/pictures,/design/resources/icons
This will mean that any image uploaded inside these paths, or inside any folder at any depth inside these will be resized.
And of course, any image outside of these paths will not be resized.
This will allow us to limit the images to be resized by the extension. For instance, the user's avatars could be resized, but what about if we don't want resized images for posts pictures?
This feature could be very helpful to save much more space in the storage and not waste the resource of Firebase.
@yulioaj290 This is exactly the feature I'm looking for in my current project. Hope your pull request goes through! 馃憤
@yulioaj290 thanks for the PR!
@jhuleatt what do you think in terms of costs? Would this actually reduce costs for the users? Also, is this going to be backward compatible?
Having an option to _include_ a list of paths (otherwise all paths would be included if the list is empty) and an option to _exclude_ paths would be very useful. This would give fine grain control.
_Example:_
Include: /images --> this would include /images and all sub-folders
Exclude: /images/do-not-resize --> exclude this specific sub-folder
An even more robust solution would be to allow each _include_ path listed to override the global _size_ setting or have a separate way of handling this. One size doesn't always fit all.
2 concerns:
I think (1) isn't a blocker, and (2) is something we can take care of in the implementation, so let's go ahead with this.
@wdm954 I think I can add another config option for the Excluded Absolute Paths, in this PR.
The thing related to the size restriction per path is more sophisticated, I vote to do that in a later PR.