Skip to content
This repository has been archived by the owner on Jun 5, 2020. It is now read-only.

Commit

Permalink
Merge pull request #263 from aharden/aharden-patch-1
Browse files Browse the repository at this point in the history
Add support and doc for configuration file
  • Loading branch information
garethr committed Dec 16, 2015
2 parents 528e87d + 371abae commit 2a75c9e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,15 @@ setting for all traffic like so:
export PUPPET_AWS_PROXY=http://localhost:8888
~~~

#### Using a configuration file

The AWS region and HTTP proxy can be provided in a file called
`puppetlabs_aws_configuration.ini` in the Puppet confdir
(`$settings::confdir`) using this format:

[default]
region = us-east-1
http_proxy = http://proxy.example.com:80

##Getting Started with aws

Expand Down
2 changes: 1 addition & 1 deletion lib/puppet_x/puppetlabs/aws.rb
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ def self.global_credentials
def self.global_configuration
Puppet.initialize_settings unless Puppet[:confdir]
path = File.join(Puppet[:confdir], 'puppetlabs_aws_configuration.ini')
File.exists?(path) ? parse_ini(File.new(path)) : nil
File.exists?(path) ? ini_parse(File.new(path)) : nil
end

def self.region_from_global_configuration
Expand Down

0 comments on commit 2a75c9e

Please sign in to comment.