scruffyfox / bitrise-amazon-s3-uploader

Bitrise Step to Deploy a file to Amazon S3
MIT License
1 stars 6 forks source link

An error occurred (SignatureDoesNotMatch) when calling the PutObject operation: The request signature we calculated does not match the signature you provided. Check your key and signing method. #6

Open sudo-justinwilson opened 3 years ago

sudo-justinwilson commented 3 years ago

We're trying out bitrise to deploy our app to iOS, and the amazon-s3-uploader step fails with the following logs:

+------------------------------------------------------------------------------+

| (11) amazon-s3-uploader@1                                                    |
+------------------------------------------------------------------------------+
| id: amazon-s3-uploader                                                       |
| version: 1.0.1                                                               |
| collection: https://github.com/bitrise-io/bitrise-steplib.git                |
| toolkit: bash                                                                |
| time: 2021-04-21T01:13:24Z                                                   |
+------------------------------------------------------------------------------+
|                                                                              |
INFO[01:13:24]  * [OK] Step dependency (aws) installed, available. 
Configs:
  * file_path: manifest.json
  * app_slug: c45f60e23889edbf
  * build_slug: 9711a59d66307cd5
  * aws_access_key: ***
  * aws_secret_key: ***
  * bucket_name: ordermentum.com/ios
  * bucket_region: ap-southeast-2
  * path_in_bucket: bitrise_c45f60e23889edbf/1618965024_build_9711a59d66307cd5
  * file_access_level: public_read
Uploading file...
upload failed: ./manifest.json to s3://ordermentum.com/ios/bitrise_c45f60e23889edbf/1618965024_build_9711a59d66307cd5/manifest.json An error occurred (SignatureDoesNotMatch) when calling the PutObject operation: The request signature we calculated does not match the signature you provided. Check your key and signing method.
Failed to upload file
  failed
|                                                                              |
+---+---------------------------------------------------------------+----------+
| x | amazon-s3-uploader@1 (exit code: 1)                           | 9.63 sec |
+---+---------------------------------------------------------------+----------+
| Issue tracker: ...://github.com/scruffyfox/bitrise-amazon-s3-uploader/issues |
| Source: https://github.com/scruffyfox/bitrise-amazon-s3-uploader             |
+---+---------------------------------------------------------------+----------+

I have tested it on my localhost (mac) with the same credentials, and it seems to work fine?

Thanks in advance for your response.

scruffyfox commented 3 years ago

Hi, Are you sure the credentials are being substituted correctly in the step? I haven't used this step in a long time, but the error suggests an issue with the input credentials (especially as you say it works locally). This might be better asked of the Bitrise team.

Are you testing this step specifically ? or just the same internal call to upload to S3?