Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(QENG-1449) proxy package managers before configuration/validation... #518

Merged
merged 1 commit into from
Nov 4, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/beaker/cli.rb
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ def provision
@hosts = []
@network_manager = Beaker::NetworkManager.new(@options, @logger)
@hosts = @network_manager.provision
@network_manager.proxy_package_manager
@network_manager.validate
@network_manager.configure
rescue => e
Expand Down
16 changes: 11 additions & 5 deletions lib/beaker/hypervisor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,15 @@ def cleanup
nil
end

#Default configuration steps to be run for a given hypervisor
#Proxy package managers on tests hosts created by this hypervisor, runs before validation and configuration.
def proxy_package_manager
if @options[:package_proxy]
package_proxy(@hosts, @options)
end
end

#Default configuration steps to be run for a given hypervisor. Any additional configuration to be done
#to the provided SUT for test execution to be successful.
def configure
if @options[:timesync]
timesync(@hosts, @options)
Expand All @@ -96,15 +104,13 @@ def configure
if @options[:add_el_extras]
add_el_extras(@hosts, @options)
end
if @options[:package_proxy]
package_proxy(@hosts, @options)
end
if @options[:disable_iptables]
disable_iptables @hosts, @options
end
end

#Default validation steps to be run for a given hypervisor
#Default validation steps to be run for a given hypervisor. Ensures that SUTs meet requirements to be
#beaker test nodes.
def validate
if @options[:validate]
validate_host(@hosts, @options)
Expand Down
4 changes: 2 additions & 2 deletions lib/beaker/network_manager.rb
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,10 @@ def configure

# configure proxy on all provioned machines
#@raise [Exception] Raise an exception if virtual machines fail to be configured
def package_proxy
def proxy_package_manager
if @hypervisors
@hypervisors.each_key do |type|
@hypervisors[type].package_proxy
@hypervisors[type].proxy_package_manager
end
end
end
Expand Down