From 971f9924e0d5b8ee3f22c2bb21c29e09daca63ca Mon Sep 17 00:00:00 2001 From: "https://www.google.com/accounts/o8/id?id=AItOawmH7o6q2l99M-PQolOfbR3_i5B_jtTIcAE" Date: Sat, 13 Sep 2014 15:29:18 +0000 Subject: [PATCH] Added a comment: How to publish your files to the public --- ..._cf6755d88463878f2ea6e4c300899027._comment | 33 +++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 doc/tips/using_Amazon_S3/comment_7_cf6755d88463878f2ea6e4c300899027._comment diff --git a/doc/tips/using_Amazon_S3/comment_7_cf6755d88463878f2ea6e4c300899027._comment b/doc/tips/using_Amazon_S3/comment_7_cf6755d88463878f2ea6e4c300899027._comment new file mode 100644 index 0000000000..3c7b817f72 --- /dev/null +++ b/doc/tips/using_Amazon_S3/comment_7_cf6755d88463878f2ea6e4c300899027._comment @@ -0,0 +1,33 @@ +[[!comment format=mdwn + username="https://www.google.com/accounts/o8/id?id=AItOawmH7o6q2l99M-PQolOfbR3_i5B_jtTIcAE" + nickname="Giovanni" + subject="How to publish your files to the public" + date="2014-09-13T15:29:18Z" + content=""" +I don't know if this is what Jack wanted, but you can upload your files to S3 and let them be accessible through a public URL. + +First, go to (or create) the bucket you will use at [S3](https://console.aws.amazon.com/s3/) and add a public get policy to it: + +``` + { + \"Version\": \"2008-10-17\", + \"Statement\": [ + { + \"Sid\": \"AllowPublicRead\", + \"Effect\": \"Allow\", + \"Principal\": { + \"AWS\": \"*\" + }, + \"Action\": \"s3:GetObject\", + \"Resource\": \"arn:aws:s3:::BUCKETNAME/*\" + } + ] + } +``` + +Then set up your special remote with the options `encryption=none`, `bucket='BUCKETNAME'` `chunk=0` (and any others you want). + +Your files will be accessible through `http://BUCKETNAME.s3-website-LOCATION.amazonaws.com/KEY` where location is the one specified through the options `datacenter` and KEY is the SHA-SOMETHING hash of the file, created by git annex and accessible if you run `git annex lookupkey FILEPATH`. + +This way you can share a link to each file you have at your S3 remote. +"""]]