有没有办法将 Strapi 媒体上传到 AWS S3 存储桶而不是公共文件夹?
我在 Heroku 上托管 Strapi CMS,它的空间有限,因此需要独立于应用程序存储媒体。
为此,我安装了 Strapi-provider-upload-aws-s3 并遵循文档中提供的所有配置步骤,但媒体仍被添加到 public/uploads 文件夹而不是我的 AWS S3 存储桶中,我无法解决为什么。我已经配置了plugins.js、middlewares.js 并更新了我的存储桶策略。
有谁知道我是否需要做其他事情才能使其适用于 Strapi 版本 4.1。 2?
I'm hosting Strapi CMS on Heroku which has a limited amount of space so need to store media independently of the app.
To do this I installed strapi-provider-upload-aws-s3 and followed all of the configuration steps provided in the documentation but media is still being added to the public/uploads folder instead of my AWS S3 bucket and I can’t work out why. I’ve configured plugins.js, middlewares.js and updated my bucket policy.
Does anyone know if I need to do anything else to get this working for Strapi version 4.1.2?
I've also tried everything on this thread but I think the solutions are for version 3 because they're not working for me.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
刚刚通过创建一个新的 Strapi 项目让它工作,发现 NPM 指令不正确。您需要将提供程序和提供程序选项包装在 config: {} 中。您还必须使用包的长名称“strapi-provider-upload-aws-s3”
Just got it working by creating a new Strapi project, and found out that the NPM instructions are incorrect. You need to wrap the provider and provider options in config: {}. You also have to use the package's long name 'strapi-provider-upload-aws-s3'