Yuvipanda has submitted this change and it was merged.

Change subject: wmflib: Return default dir when role::puppet::self isn't used
......................................................................


wmflib: Return default dir when role::puppet::self isn't used

Bug: T120159
Change-Id: Ia59e587ff56fce628556fe556f9fa9f759b82945
---
M modules/wmflib/lib/puppet/parser/functions/puppet_ssldir.rb
1 file changed, 4 insertions(+), 2 deletions(-)

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



diff --git a/modules/wmflib/lib/puppet/parser/functions/puppet_ssldir.rb 
b/modules/wmflib/lib/puppet/parser/functions/puppet_ssldir.rb
index 58cbad9..d0e8446 100644
--- a/modules/wmflib/lib/puppet/parser/functions/puppet_ssldir.rb
+++ b/modules/wmflib/lib/puppet/parser/functions/puppet_ssldir.rb
@@ -45,11 +45,13 @@
     # Since all self-hosted puppetmasters are in .eqiad.wmflabs, while
     # the labs masters don't
     return default if lookupvar('::settings::certname') =~ /\.wikimedia\.org$/
-
     # Non-self-hosted puppetmasters all use the default ssldir
     puppetmaster = lookupvar('puppetmaster')
     puppetmaster ||= function_hiera(['role::puppet::self::master', ''])
-    if [lookupvar('hostname'), 'localhost', '', nil].include?puppetmaster
+    if puppetmaster == ''
+      # Means we aren't using any of role::puppet::self!1!
+      default
+    elsif [lookupvar('hostname'), 'localhost', '', nil].include?puppetmaster
       self_master
     else
       self_client

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

Gerrit-MessageType: merged
Gerrit-Change-Id: Ia59e587ff56fce628556fe556f9fa9f759b82945
Gerrit-PatchSet: 7
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Yuvipanda <yuvipa...@wikimedia.org>
Gerrit-Reviewer: Yuvipanda <yuvipa...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to