Sha256: bb6aff965e72e5ba10e45929fbfd40a8864930b25857af3e2838b1b82014803c
Contents?: true
Size: 1.34 KB
Versions: 36
Compression:
Stored size: 1.34 KB
Contents
# installs Amazon's awscli tools # mod by rpc to include epel case node['platform'] when 'debian', 'ubuntu' file = "/usr/local/bin/aws" cmd = "apt-get install -y python-pip && pip install awscli" when 'redhat', 'centos', 'fedora', 'amazon', 'scientific' # must include epel for centos. For now do in roles until we fix egt-get-cookbooks.sh #include_recipe "mu-utility::epel" file = "/usr/bin/aws" cmd = "yum -y install python-pip && pip install awscli" end r = execute "install awscli" do command cmd not_if { ::File.exist?(file) } if node['awscli']['compile_time'] action :nothing end end if node['awscli']['compile_time'] r.run_action(:run) end if node['awscli']['config_profiles'] config_file="/root/.aws/config" r = directory ::File.dirname(config_file) do recursive true owner 'root' group 'root' mode 00700 not_if { ::File.exist?(::File.dirname(config_file)) } if node['awscli']['compile_time'] action :nothing end end if node['awscli']['compile_time'] r.run_action(:create) end r = template config_file do mode 00600 owner 'root' group 'root' source 'config.erb' not_if { ::File.exist?(config_file) } if node['awscli']['compile_time'] action :nothing end end if node['awscli']['compile_time'] r.run_action(:create) end end
Version data entries
36 entries across 36 versions & 1 rubygems