Last active
August 29, 2015 13:58
-
-
Save commuterjoy/9977285 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# transfer locally cached resources to s3 (single threaded) | |
s3: | |
s3cmd put -m text/html --add-header 'Cache-Control: max-age=60' --acl-public --recursive target/cache/www.theguardian.com/books s3://aws-frontend-archive/www.theguardian.com/ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://github.com/chrishein/s3_uploader - this is nice | |
require 'rubygems' | |
require 's3_uploader' | |
S3Uploader.upload_directory('target/cache/www.theguardian.com', 'aws-frontend-archive', | |
{ | |
:destination_dir => 'www.theguardian.com', | |
:region => 'eu-west-1', | |
:threads => 15, | |
:metadata => { | |
'Cache-Control' => 'max-age=60', | |
'Content-Type' => 'text/html', | |
'x-amz-acl' => 'public-read' | |
} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment