Method: ConfCtl::MachineStatus#evaluate
- Defined in:
- lib/confctl/machine_status.rb
#evaluate ⇒ Object
119 120 121 122 123 124 125 126 127 128 129 130 |
# File 'lib/confctl/machine_status.rb', line 119 def evaluate @swpins_state = {} target_swpin_specs.each do |name, spec| swpins_state[name] = SwpinState.new(spec, swpins_info && swpins_info[name]) end outdated_swpins = swpins_state.detect { |_k, v| v.outdated? } @online = uptime ? true : false @status = online? && !outdated_swpins @status = false if target_toplevel && target_toplevel != current_toplevel end |