Module: SSHKit::Runner::Group::NoTrailingWait
- Included in:
- SSHKit::Runner::Group
- Defined in:
- lib/kamal/sshkit_with_ext.rb
Overview
SSHKit sleeps after every slice, including the last, so a paced role pays one wait interval buying nothing — there is no next group for it to pace against. Kamal's boot wait means "hold off before starting the next group", which is what Sequential already does by popping its last host.
Instance Method Summary collapse
Instance Method Details
#execute ⇒ Object
218 219 220 221 222 223 224 225 226 |
# File 'lib/kamal/sshkit_with_ext.rb', line 218 def execute slices = hosts.each_slice(group_size).to_a slices.each_with_index.flat_map do |group_hosts, index| result = SSHKit::Runner::Parallel.new(group_hosts, &block).execute sleep wait_interval if index < slices.size - 1 result end end |