jenkins-bot has submitted this change and it was merged.
Change subject: Allow `null` in mediawiki::settings configuration
......................................................................
Allow `null` in mediawiki::settings configuration
Fix ::role::simple_miser and make setting configuration variables to
null easy in the general case by properly handling the Puppet `undef`
value as PHP's `null` when generating configuration snippets.
Change-Id: Ib0a33bdf265585f985d53a4cf458128a7645e9da
---
M puppet/modules/mediawiki/templates/settings.php.erb
M puppet/modules/mediawiki/templates/wiki/wgConf.php.erb
M puppet/modules/role/manifests/simple_miser.pp
3 files changed, 5 insertions(+), 5 deletions(-)
Approvals:
BryanDavis: Looks good to me, approved
Subramanya Sastry: Looks good to me, but someone else must approve
jenkins-bot: Verified
diff --git a/puppet/modules/mediawiki/templates/settings.php.erb
b/puppet/modules/mediawiki/templates/settings.php.erb
index 3f12c64..44ee826 100644
--- a/puppet/modules/mediawiki/templates/settings.php.erb
+++ b/puppet/modules/mediawiki/templates/settings.php.erb
@@ -5,8 +5,8 @@
<%=
def phpize(o)
case o
- when nil then
- 'NULL'
+ when nil, :undef then
+ 'null'
when Array
'array( ' + o.map { |x| phpize(x) }.join(', ') + ' )'
when Hash
diff --git a/puppet/modules/mediawiki/templates/wiki/wgConf.php.erb
b/puppet/modules/mediawiki/templates/wiki/wgConf.php.erb
index 9a1eafc..78713f9 100644
--- a/puppet/modules/mediawiki/templates/wiki/wgConf.php.erb
+++ b/puppet/modules/mediawiki/templates/wiki/wgConf.php.erb
@@ -15,8 +15,8 @@
<%=
def phpize(o)
case o
- when nil then
- 'NULL'
+ when nil, :undef then
+ 'null'
when Array
'array( ' + o.map { |x| phpize(x) }.join(', ') + ' )'
when Hash
diff --git a/puppet/modules/role/manifests/simple_miser.pp
b/puppet/modules/role/manifests/simple_miser.pp
index ad19db5..66ddb3d 100644
--- a/puppet/modules/role/manifests/simple_miser.pp
+++ b/puppet/modules/role/manifests/simple_miser.pp
@@ -13,7 +13,7 @@
values => {
# Database
wgMiserMode => true,
- wgSQLMode => 'null',
+ wgSQLMode => undef,
wgUseFileCache => true,
wgUseGzip => true,
wgFileCacheDepth => 0,
--
To view, visit https://gerrit.wikimedia.org/r/283747
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ib0a33bdf265585f985d53a4cf458128a7645e9da
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/vagrant
Gerrit-Branch: master
Gerrit-Owner: BryanDavis <[email protected]>
Gerrit-Reviewer: BryanDavis <[email protected]>
Gerrit-Reviewer: Dduvall <[email protected]>
Gerrit-Reviewer: Subramanya Sastry <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits