Module: PeInfo::System
- Defined in:
- lib/pe_info/system.rb
Constant Summary collapse
- AGENT_UPLOAD_PATH_NORMAL =
'/opt/puppetlabs/server/data/staging'
- AGENT_UPLOAD_PATH_WINDOWS =
'/opt/puppetlabs/server/data/packages/public'
Class Method Summary collapse
- .agent_installer_upload_path_normal(agent_version) ⇒ Object
- .agent_installer_upload_path_windows_x64(pe_version, agent_version) ⇒ Object
- .agent_installer_upload_path_windows_x86(pe_version, agent_version) ⇒ Object
- .upload_path(pe_version, agent_version, installer) ⇒ Object
Class Method Details
.agent_installer_upload_path_normal(agent_version) ⇒ Object
6 7 8 9 |
# File 'lib/pe_info/system.rb', line 6 def self.agent_installer_upload_path_normal(agent_version) "#{AGENT_UPLOAD_PATH_NORMAL}/pe_repo-puppet-agent-#{agent_version}" end |
.agent_installer_upload_path_windows_x64(pe_version, agent_version) ⇒ Object
15 16 17 |
# File 'lib/pe_info/system.rb', line 15 def self.agent_installer_upload_path_windows_x64(pe_version, agent_version) "/#{AGENT_UPLOAD_PATH_WINDOWS}/#{pe_version}/windows-x86_64-#{agent_version}" end |
.agent_installer_upload_path_windows_x86(pe_version, agent_version) ⇒ Object
11 12 13 |
# File 'lib/pe_info/system.rb', line 11 def self.agent_installer_upload_path_windows_x86(pe_version, agent_version) "/#{AGENT_UPLOAD_PATH_WINDOWS}/#{pe_version}/windows-i386-#{agent_version}" end |
.upload_path(pe_version, agent_version, installer) ⇒ Object
19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/pe_info/system.rb', line 19 def self.upload_path(pe_version, agent_version, installer) if installer =~ /puppet-agent-x64.msi/ path = agent_installer_upload_path_windows_x64(pe_version, agent_version) elsif installer =~ /puppet-agent-x86.msi/ path = agent_installer_upload_path_windows_x86(pe_version, agent_version) else path = agent_installer_upload_path_normal(agent_version) end path end |