Please review pull request #190: (maint) allow console port to be set thru env vars opened by (justinstoller)
Description:
Previously the only way to set the consoleport was through the config files. This works fine for installs from old tagged config files, but it doesn't work for upgrades.
- Opened: Mon Apr 09 05:54:44 UTC 2012
- Based on: puppetlabs:master (d7d701826a3aad2cb9580b9aeea700f797e92663)
- Requested merge: justinstoller:maint/master/allow_consoleport_set_from_env_vars (ead732c98f2c4037503022556dce519f4169401c)
Diff follows:
diff --git a/lib/test_config.rb b/lib/test_config.rb
index d40fe49..bb9f9ac 100644
--- a/lib/test_config.rb
+++ b/lib/test_config.rb
@@ -17,7 +17,8 @@ def self.ssh_defaults
def self.load_file(config_file)
config = YAML.load_file(config_file)
# Merge some useful date into the config hash
- config['CONFIG']['consoleport'] = 443 unless config['CONFIG']['consoleport']
+ consoleport = ENV['consoleport'] || config['CONFIG']['consoleport'] || 443
+ config['CONFIG']['consoleport'] = consoleport
config['CONFIG']['ssh'] = ssh_defaults.merge(config['CONFIG']['ssh'] || {})
config['CONFIG']['pe_ver'] = puppet_enterprise_version if is_pe?
config['CONFIG']['pe_ver_win'] = puppet_enterprise_version_win if is_pe?
-- You received this message because you are subscribed to the Google Groups "Puppet Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to [email protected].
For more options, visit this group at http://groups.google.com/group/puppet-dev?hl=en.
