Permalink
Browse files

Enable customization of aws credentials.

  • Loading branch information...
1 parent e7d133e commit 24a306e63071270c93fac0cbcd25f67b3f75086b @freerobby committed Nov 2, 2011
Showing with 10 additions and 4 deletions.
  1. +2 −0 README.rdoc
  2. +5 −1 attributes/default.rb
  3. +1 −1 metadata.json
  4. +2 −2 templates/default/s3cfg.erb
View
@@ -9,6 +9,8 @@ Installs and configures s3cmd
All node attributes are set under the :s3cmd namespace.
* :users - array of usernames for whom a .s3cfg will be created in their home directory; defaults to [:root]
+* :aws_access_key_id - AWS access key for S3
+* :aws_secret_access_key - AWS secret access key for S3
= USAGE:
View
@@ -1,2 +1,6 @@
# list of users that will have the s3cmd configuration
-default[:s3cmd][:users] = [:root]
+default[:s3cmd][:users] = [:root]
+
+# S3 credentials
+default[:s3cmd][:aws_access_key_id] = ""
+default[:s3cmd][:aws_secret_access_key] = ""
View
@@ -1,7 +1,7 @@
{
"name": "s3cmd",
"description": "Installs and configures s3cmd",
- "long_description": "= DESCRIPTION:\n\nInstalls and configures s3cmd\n\n= REQUIREMENTS:\n\n= ATTRIBUTES:\n\nAll node attributes are set under the :s3cmd namespace.\n\n* :users - array of usernames for whom a .s3cfg will be created in their home directory; defaults to [:root]\n\n= USAGE:\n\nJust add the s3cmd recipe to the applicable nodes",
+ "long_description": "= DESCRIPTION:\n\nInstalls and configures s3cmd\n\n= REQUIREMENTS:\n\n= ATTRIBUTES:\n\nAll node attributes are set under the :s3cmd namespace.\n\n* :users - array of usernames for whom a .s3cfg will be created in their home directory; defaults to [:root]\n* :aws_access_key_id - AWS access key for S3\n* :aws_secret_access_key - AWS secret access key for S3\n\n= USAGE:\n\nJust add the s3cmd recipe to the applicable nodes",
"maintainer": "Enis Soztutar",
"maintainer_email": "enis@speeddate.com",
"license": "Apache 2.0",
@@ -1,5 +1,5 @@
[default]
-access_key = YOUR_ACCESS_KEY
+access_key = <%= node[:s3cmd][:aws_access_key_id] %>
acl_public = False
bucket_location = US
cloudfront_host = cloudfront.amazonaws.com
@@ -26,7 +26,7 @@ proxy_host =
proxy_port = 0
recursive = False
recv_chunk = 4096
-secret_key = YOUR_SECRET_KEY
+secret_key = <%= node[:s3cmd][:aws_secret_access_key] %>
send_chunk = 4096
simpledb_host = sdb.amazonaws.com
skip_existing = False

0 comments on commit 24a306e

Please sign in to comment.