1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-16 22:50:10 +03:00

M #-: auto for dummy monitoring. Checks

This commit is contained in:
Ruben S. Montero 2020-05-26 16:07:58 +02:00
parent 2c19a586d0
commit e28f5d8d01
No known key found for this signature in database
GPG Key ID: A0CEA6FA880A1D87

View File

@ -170,10 +170,14 @@ begin
hostid = config.elements['HOST_ID'].text.to_s
if host == 'auto'
if local? hyperv
if local? hyperv || hyperv == 'dummy'
host = '127.0.0.1'
else
host = ENV['SSH_CLIENT'].split.first
begin
host = ENV['SSH_CLIENT'].split.first
rescue
host = ''
end
if host.to_s.empty?
puts 'NETWORK/MONITOR_ADDRESS is "auto", but SSH_CLIENT unknown'