2010-09-12 17:44:58 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2010-11-13 15:38:26 +00:00
|
|
|
class AwsIamTools < AmazonWebServicesFormula
|
2012-07-01 20:39:25 +00:00
|
|
|
homepage 'http://aws.amazon.com/developertools/4143'
|
2012-03-20 02:37:13 +00:00
|
|
|
url 'http://awsiammedia.s3.amazonaws.com/public/tools/cli/latest/IAMCli.zip'
|
2012-09-03 18:33:56 +00:00
|
|
|
sha1 'a2bd3048327d1ee34e20abbc8e2cc6c68ebdee5f'
|
2012-07-01 20:39:25 +00:00
|
|
|
version "1.5.0"
|
2010-09-12 17:44:58 +00:00
|
|
|
|
|
|
|
def install
|
2010-11-13 15:38:26 +00:00
|
|
|
standard_install
|
2010-09-12 17:44:58 +00:00
|
|
|
end
|
|
|
|
|
2012-03-05 00:56:59 +00:00
|
|
|
def caveats; <<-EOS.undent
|
|
|
|
Before you can use these tools you must export some variables to your $SHELL
|
|
|
|
and create a file containing your aws credentials.
|
2010-09-12 17:44:58 +00:00
|
|
|
|
2012-03-05 00:56:59 +00:00
|
|
|
You can access your AWS access ID and AWS secret key:
|
|
|
|
http://aws-portal.amazon.com/gp/aws/developer/account/index.html?action=access-key
|
2010-09-12 17:44:58 +00:00
|
|
|
|
2012-03-05 00:56:59 +00:00
|
|
|
You must create the file $HOME/.aws-credentials-master, here is a template:
|
2010-09-12 17:44:58 +00:00
|
|
|
|
2012-03-05 00:56:59 +00:00
|
|
|
# Enter the AWS Keys without the < or >
|
|
|
|
# You can either use the AWS Accounts access keys and they can be found at
|
|
|
|
# http://aws.amazon.com under Account->Security Credentials
|
|
|
|
# or you can use the access keys of a user created with IAM
|
|
|
|
AWSAccessKeyId=<Write your AWS access ID>
|
|
|
|
AWSSecretKey=<Write your AWS secret key>
|
2010-09-12 17:44:58 +00:00
|
|
|
|
2012-03-05 00:56:59 +00:00
|
|
|
To preserve your credentials don't forget to:
|
|
|
|
chmod 600 $HOME/.aws-credentials-master
|
2010-09-12 17:44:58 +00:00
|
|
|
|
2012-03-05 00:56:59 +00:00
|
|
|
To export the needed variables, add them to your dotfiles.
|
|
|
|
* On Bash, add them to `~/.bash_profile`.
|
|
|
|
* On Zsh, add them to `~/.zprofile` instead.
|
2012-01-28 19:25:36 +00:00
|
|
|
|
2012-03-05 00:56:59 +00:00
|
|
|
export JAVA_HOME="$(/usr/libexec/java_home)"
|
2013-11-26 21:48:04 +00:00
|
|
|
export AWS_IAM_HOME="#{opt_prefix}/libexec"
|
2012-03-05 00:56:59 +00:00
|
|
|
export AWS_CREDENTIAL_FILE=$HOME/.aws-credentials-master
|
2010-09-12 17:44:58 +00:00
|
|
|
EOS
|
|
|
|
end
|
|
|
|
end
|