Pradeeplogme / s3-bash

Automatically exported from code.google.com/p/s3-bash
Other
0 stars 0 forks source link

can't put files to European buckets #7

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. create a bucket with location set to europe
2. attempt to put a file in that bucket

What is the expected output? What do you see instead?
It should upload, but instead an error is returned regarding permanent
endpoint redirection ... this is actually expected behavior (see
http://docs.amazonwebservices.com/AmazonS3/2006-03-01/LocationSelection.html)

What version of the product are you using? On what operating system?
v0.02 on Ubuntu Linux

Please provide any additional information below.
I've implemented a simple fix which works with European and US buckets
(patches to s3-put and s3-common-functions attached)

Original issue reported on code.google.com by jon.k...@gmail.com on 14 Nov 2007 at 5:21

Attachments:

GoogleCodeExporter commented 8 years ago
Looks like my "fix" breaks s3-get and s3-delete ... oops.
I forgot to add the following lines to s3-get and s3-delete below the call to 
verifyUrl:

bucketName=`echo $url | cut -d '/' -f2`
urlSuffix=`expr match "$url" "\/$bucketName\(\/.*\)"`

Original comment by jon.k...@gmail.com on 16 Nov 2007 at 7:17

GoogleCodeExporter commented 8 years ago
on osx you need urlSuffix=`expr "$url" : "\/$bucketName\(\/.*\)"` as the syntax 
seem to be different...

Original comment by batl...@gmail.com on 8 Dec 2008 at 2:36

GoogleCodeExporter commented 8 years ago
This fix worked great for me on SuSE Linux 10.3. Thanks, jon.keys!

Original comment by admin%dn...@gtempaccount.com on 3 Feb 2009 at 6:12

GoogleCodeExporter commented 8 years ago
Cheers guys, 5 years on and these patches are still useful! (fixed same issue 
for me on OS X 10.8.1)

Original comment by brynblac...@gmail.com on 17 Sep 2012 at 11:39