s3-plugin-webpack: SigV4 error issue
My bucket is in ap-northeast-2 which has to set SigV4. When I build, it cannot upload to S3 with message
ERROR in S3Plugin: Error: Non-file stream objects are not supported with SigV4 in AWS.S3
Do you have plan to add an ‘option’ for SigV4?
My environment is below:
Node v4.2.3 webpack-s3-plugin@0.8.0 OSX 10.10.5
Example config
module.exports = {
new S3Plugin({
// s3Options are required
s3Options: {
accessKeyId: process.env.AWS_ACCESS_KEY_ID,
secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY,
region: 'ap-northeast-2'
},
s3UploadOptions: {
Bucket: 'my'
}
})
]
};
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 3
- Comments: 26 (6 by maintainers)
Commits related to this issue
- chore(packages): Update s3 to point at master s3 is a dead project, this needs to be switched over to use aws sdk directly since we already use it for cloudfront. This will temporarily unblock #43 un... — committed to MikaAK/s3-plugin-webpack by MikaAK 7 years ago
- chore(packages): Update s3 to point at master (#85) s3 is a dead project, this needs to be switched over to use aws sdk directly since we already use it for cloudfront. This will temporarily unblock ... — committed to MikaAK/s3-plugin-webpack by MikaAK 6 years ago
I was able to fix this by pointing my package.json to the following branch:
“webpack-s3-plugin”: “https://github.com/johnf/s3-plugin-webpack#soaa”
As long as this problem exists you can use my hacky fork. https://github.com/fabianfett/s3-plugin-webpack just
Hope that helps.
Since there is not a hotfix, You can use this repo as well: “webpack-s3-plugin”: “git+https://github.com/eyupci/s3-plugin-webpack.git#master”
@denyago it seems like problem only with ‘eu-central-1’ region. Frankfurt. Try to use Ireland region. It solved this problem for me.
with
signatureVersion: 'v3':I get:
with
signatureVersion: 'v4':I get:
I’ve been having the same errors while trying to use this plugin … the fix from @fabianfett seemed to work
@MikaAK Sorry, but i still don’t get how to make it work now? Is it problem with my bucket, or with my config? Or
s3-plugin-webpackdon’t work at all for now?Thank you for your quick comment! You are right, this is not a bug so you may close it. 😃 I’ll try to PR but since I’m a beginner of Webpack and Javascript, it takes a long time.