Skip to content

Commit

Permalink
Merge pull request crowbar#1070 from jsuchome/timeouts
Browse files Browse the repository at this point in the history
Increase timeouts for upgrade related actions
  • Loading branch information
jsuchome committed Feb 7, 2017
2 parents f317da8 + 89f7b06 commit 967b7dc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions crowbar_framework/app/models/api/node.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ def prepare_repositories
end

def os_upgrade
execute_and_wait_for_finish("/usr/sbin/crowbar-upgrade-os.sh", 600)
execute_and_wait_for_finish("/usr/sbin/crowbar-upgrade-os.sh", 900)
Rails.logger.info("Package upgrade was successful.")
rescue StandardError => e
Api::Upgrade.raise_node_upgrade_error(
Expand All @@ -74,7 +74,7 @@ def join_and_chef
@node.save
end
begin
execute_and_wait_for_finish("/usr/sbin/crowbar-chef-upgraded.sh", 600)
execute_and_wait_for_finish("/usr/sbin/crowbar-chef-upgraded.sh", 900)
rescue StandardError => e
Api::Upgrade.raise_node_upgrade_error(
"Error while running the initial chef-client. " + e.message
Expand All @@ -94,7 +94,7 @@ def join_and_chef
end

def wait_for_ssh_state(desired_state, action)
Timeout.timeout(300) do
Timeout.timeout(400) do
loop do
ssh_status = @node.ssh_cmd("").first
break if desired_state == :up ? ssh_status == 200 : ssh_status != 200
Expand Down

0 comments on commit 967b7dc

Please sign in to comment.