Ottomata has submitted this change and it was merged.

Change subject: Supporting both short hostnames and fqdn for labs 
role::puppet::self
......................................................................


Supporting both short hostnames and fqdn for labs role::puppet::self

Change-Id: I95c050ff64570c31860410546981796f673aea12
---
M manifests/role/puppet.pp
1 file changed, 4 insertions(+), 1 deletion(-)

Approvals:
  Ottomata: Verified; Looks good to me, approved
  jenkins-bot: Verified



diff --git a/manifests/role/puppet.pp b/manifests/role/puppet.pp
index 65d37c0..6a54def 100644
--- a/manifests/role/puppet.pp
+++ b/manifests/role/puppet.pp
@@ -56,7 +56,10 @@
                undef       => 'localhost',
                'localhost' => 'localhost',
                ''          => 'localhost',
-               default     => "${::puppetmaster}.${domain}",
+               # if only word characters, assume that this is a short hostname
+               /^\w+$/     => "${::puppetmaster}::${::domain}",
+               # else use assume fqdn
+               default     => $::puppetmaster,
        }
 
        # If localhost or if $server matches this node's

-- 
To view, visit https://gerrit.wikimedia.org/r/75158
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I95c050ff64570c31860410546981796f673aea12
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Ottomata <[email protected]>
Gerrit-Reviewer: Ottomata <[email protected]>
Gerrit-Reviewer: Ryan Lane <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to