How to set expires headers to all images in a bucket in Amazon S3

后端 未结 6 1092
予麋鹿
予麋鹿 2020-12-23 11:59

We have around 10,000+ images in a bucket in Amazon S3, how can I set the expires header on all of the images in one go?

6条回答
  •  一向
    一向 (楼主)
    2020-12-23 12:19

    You can make bulk changes to bucket files with third party apps that use the S3 API. Those apps will not set the headers using only one request, but will automate the 10,000+ required requests.

    The one I currently use is Cloudberry Explorer, which is a freeware utility to interact with your S3 buckets. In this tool I can select multiple files and specify HTTP headers that will be applied to all of them.

    enter image description here

    enter image description here

    An alternative would be to develop your own script or tool using the S3 API libraries.

提交回复
热议问题