You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Passing in a URL into the --website-redirect option is considered invalid, despite including a valid prefix.
% aws s3 cp --website-redirect 'http://otherserver.com' /var/folders/mr/hp5q732j74b25ht_d_2tn8bh0000gn/T/redirect.XXXXXX.2RcCGLGT s3://mys3bucket.server.com/path/to/index.html
upload failed: ../../../../var/folders/mr/hp5q732j74b25ht_d_2tn8bh0000gn/T/redirect.XXXXXX.2RcCGLGT to s3://mys3bucket.server.com/path/to/index.html
A client error (InvalidRedirectLocation) occurred when calling the PutObject operation:
The website redirect location must have a prefix of 'http://' or 'https://' or '/'.
I have tried with both http and https (however if I use https on a site that doesn't have a valid cert I get a ssl error). Also tried a variety of escaping and quoting the url including, none of which worked 😢
I can reproduce the issue as well. It makes sense that it works again in 1.4 because that was around the time we made the switch on some of the internals of the s3 commands.
The --website-redirect argument is trying to using the contents at that web address since it is a feature in the CLI that if you prepend an argument values with http:// or https://, it will try to retrieve the contents of the web address and use that as the value to the argument.
The solution is that we must black list that feature from this argument. Working on a fix for it.
* chore(version): set 0.14.3.dev1 version (aws#1112) (aws#1113)
* Depend on development version of lambda-builders for dev builds (aws#1111)
* Depend on development version of lambda-builders for dev builds
* Adding prod.txt to manifest
* Splitting dev and tool dependencies
* fix(build): Resolve path after .aws-sam is created (aws#1110)
* fix(build): Resolve path after .aws-sam is created
* fix: build (make pr)
* Design and implementation for producing debug build artifacts (aws#1095)
* design: Initial Design for producing debug artifacts
* initial implementation
* Adding unit tests
* Integration test with debug build mode
* Adjust Design doc and add keyword arg to a call
* fix(dotnet): init template fixes (aws#1117)
* chore(version): set 0.15.0 (aws#1125)
* Revert "Depend on development version of lambda-builders for dev builds (aws#1111)" (aws#1128)
This reverts commit 7e9de790e23791ba176faff2030286db4007e503.
* Bumping to Lambda Builders 0.3.0 (aws#1129)
Bumping to Lambda Builders 0.3.0
* fix(func-tests): add dependency manager param (aws#1130)
Passing in a URL into the
--website-redirect
option is considered invalid, despite including a valid prefix.I have tried with both http and https (however if I use https on a site that doesn't have a valid cert I get a ssl error). Also tried a variety of escaping and quoting the url including, none of which worked 😢
aws s3 cp --website-redirect 'http://otherserver.com' file s3://mys3bucket/path/file
aws s3 cp --website-redirect "http://otherserver.com" file s3://mys3bucket/path/file
aws s3 cp --website-redirect http://otherserver.com file s3://mys3bucket/path/file
aws s3 cp --website-redirect http:\/\/otherserver.com file s3://mys3bucket/path/file
aws s3 cp --website-redirect https://otherserver.com file s3://mys3bucket/path/file
aws s3 cp file s3://mys3bucket/path/file --website-redirect "http://otherserver.com"
I was able to roll back to version 1.4 and get the command to work again.
The text was updated successfully, but these errors were encountered: