diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/facter/alt_fqdns.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/facter/alt_fqdns.rb b/lib/facter/alt_fqdns.rb index 89c4b6a..216beef 100644 --- a/lib/facter/alt_fqdns.rb +++ b/lib/facter/alt_fqdns.rb @@ -31,3 +31,14 @@ end end end +# map ctlplane network to management fqdn +Facter.add('fqdn_ctlplane') do + setcode do + hostname_parts = [ + Facter.value(:hostname), + 'management', + Facter.value(:domain), + ].reject { |part| part.nil? || part.empty? } + hostname_parts.join(".") + end +end |