Make fqdn fact names match service net map
authorJuan Antonio Osorio Robles <jaosorior@redhat.com>
Mon, 5 Sep 2016 11:33:45 +0000 (14:33 +0300)
committerJuan Antonio Osorio Robles <jaosorior@redhat.com>
Mon, 5 Sep 2016 11:33:45 +0000 (14:33 +0300)
This will make it easier to use and consume from t-h-t, making their
use more dynamic. This is still safe to do, since these are not used
by anything yet.

Change-Id: I4d603938c568320d4ae1cc7a396070ad4ac62132

lib/facter/alt_fqdns.rb

index 8a4d59b..89c4b6a 100644 (file)
@@ -14,9 +14,9 @@
 # under the License.
 [
   'external',
-  'internalapi',
+  'internal_api',
   'storage',
-  'storagemgmt',
+  'storage_mgmt',
   'tenant',
   'management',
 ].each do |network|
@@ -24,7 +24,7 @@
     setcode do
       external_hostname_parts = [
         Facter.value(:hostname),
-        network,
+        network.gsub('_', ''),
         Facter.value(:domain),
       ].reject { |part| part.nil? || part.empty? }
       external_hostname_parts.join(".")