Reescrevendo cabeçalhos s3 simultaneamente

https://gist.github.com/3359321 from boto.s3.connection import S3Connectionfrom futures import ThreadPoolExecutorimport futuresconnection = S3Connection(‘id’, ‘key’)import logginglogging.basicConfig(level=logging.INFO)def mod_key(key): “””Rewrite the headers of js files in js/ “”” if not key.name.startswith(“js/”) or not key.name.endswith(‘.js’): logging.info(“not …

Continuar lendo

Permissão para ler no Amazon S3

Basta adicionar estas linhas abaixo no Bucket Policy Editor: { “Version”: “2008-10-17”, “Statement”: [ { “Sid”: “AllowPublicRead”, “Effect”: “Allow”, “Principal”: { “AWS”: “*” }, “Action”: “s3:GetObject”, “Resource”: “arn:aws:s3:::your_buckt_name/*” } ]}

Continuar lendo