Class: Facts::Linux::Hypervisors::SystemdNspawn

Inherits:
Object
  • Object
show all
Defined in:
lib/facter/facts/linux/hypervisors/systemd_nspawn.rb

Constant Summary collapse

FACT_NAME =
'hypervisors.systemd_nspawn'

Instance Method Summary collapse

Instance Method Details

#call_the_resolverObject



9
10
11
12
# File 'lib/facter/facts/linux/hypervisors/systemd_nspawn.rb', line 9

def call_the_resolver
  fact_value = check_nspawn
  Facter::ResolvedFact.new(FACT_NAME, fact_value)
end

#check_nspawnObject



14
15
16
17
# File 'lib/facter/facts/linux/hypervisors/systemd_nspawn.rb', line 14

def check_nspawn
  info = Facter::Resolvers::Containers.resolve(:hypervisor)
  info[:systemd_nspawn] if info
end