Sha256: 06d1b1bcb4c761d503e7270ec76f0ed6e2a7a217312ea25c20afec8a48bcd244

Contents?: true

Size: 744 Bytes

Versions: 7

Compression:

Stored size: 744 Bytes

Contents

target_test 'hostname is set' do |config|
  if config[:hostname].blank? && !config[:host].blank?
    next {
      severity: :warning,
      message: "config has a host (#{config[:host]}) but is missing a hostname"
    }
  end
end

target_test 'hostnames in ssh config' do |config|
  next if config[:hostname].blank?

  unless ssh_hostnames.include? config[:hostname]
    {severity: :info, message: "config has a hostname (#{config[:hostname]}) which is not in your ssh config"}
  end
end

target_test 'required hostnames' do |config|
  types = %i[rsync rsync_with_version maria]
  if types.include?(config[:type]) && config[:hostname].blank?
    next { severity: :error, message: "config requires a hostname (#{config[:hostname]})" }
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
fulmar-2.2.6 lib/fulmar/domain/service/config_tests/hosts.rb
fulmar-2.2.5 lib/fulmar/domain/service/config_tests/hosts.rb
fulmar-2.2.4 lib/fulmar/domain/service/config_tests/hosts.rb
fulmar-2.2.3 lib/fulmar/domain/service/config_tests/hosts.rb
fulmar-2.2.2 lib/fulmar/domain/service/config_tests/hosts.rb
fulmar-2.2.1 lib/fulmar/domain/service/config_tests/hosts.rb
fulmar-2.2.0 lib/fulmar/domain/service/config_tests/hosts.rb