Skip to content

Commit

Permalink
Merge pull request redhat-openstack#210 from txaj/fix-booleans-pulled…
Browse files Browse the repository at this point in the history
…-from-hiera

Ensure variable using 'false' will be interpreted.
  • Loading branch information
blkperl committed Dec 12, 2014
2 parents 3fae4b2 + 8ef18e6 commit 385e9e7
Show file tree
Hide file tree
Showing 10 changed files with 20 additions and 20 deletions.
4 changes: 2 additions & 2 deletions templates/plugin/apache.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
<% if values['password'] -%>
Password "<%= values['password'] %>"
<% end -%>
<% if values['verifypeer'] -%>
<% unless values['verifypeer'].nil? -%>
VerifyPeer "<%= values['verifypeer'] %>"
<% end -%>
<% if values['verifyhost'] -%>
<% unless values['verifyhost'].nil? -%>
VerifyHost "<%= values['verifyhost'] %>"
<% end -%>
<% if values['cacert'] -%>
Expand Down
6 changes: 3 additions & 3 deletions templates/plugin/bind.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
MemoryStats <%= @memorystats %>
<% @views.each do |view| -%>
<View "<%= view['name'] %>">
<% if view['qtypes'] -%>
<% unless view['qtypes'].nil? -%>
QTypes <%= view['qtypes'] %>
<% end -%>
<% if view['resolverstats'] -%>
<% unless view['resolverstats'].nil? -%>
ResolverStats <%= view['resolverstats'] %>
<% end -%>
<% if view['cacherrsets'] -%>
<% unless view['cacherrsets'].nil? -%>
CacheRRSets <%= view['cacherrsets'] %>
<% end -%>
<% if view['zones'] -%>
Expand Down
2 changes: 1 addition & 1 deletion templates/plugin/match.tpl.erb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<% @matches.each do |match| -%>
<Match>
Regex "<%= match['regex'] %>"
<% if match['excluderegex'] -%>
<% unless match['excluderegex'].nil? -%>
ExcludeRegex "<%= match['excluderegex'] %>"
<% end -%>
DSType "<%= match['dstype'] %>"
Expand Down
4 changes: 2 additions & 2 deletions templates/plugin/network.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@
<% if @maxpacketsize -%>
MaxPacketSize <%= @maxpacketsize %>
<% end -%>
<% if @forward -%>
<% unless @forward.nil? -%>
Forward "<%= @forward %>"
<% end -%>
<% if @reportstats -%>
<% unless @reportstats.nil? -%>
ReportStats "<%= @reportstats %>"
<% end -%>

Expand Down
4 changes: 2 additions & 2 deletions templates/plugin/nginx.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@
<% if @password -%>
Password "<%= @password %>"
<% end -%>
<% if @verifypeer -%>
<% unless @verifypeer.nil? -%>
VerifyPeer <%= @verifypeer %>
<% end -%>
<% if @verifyhost -%>
<% unless @verifyhost.nil? -%>
VerifyHost <%= @verifyhost %>
<% end -%>
<% if @cacert -%>
Expand Down
2 changes: 1 addition & 1 deletion templates/plugin/postgresql/writer.conf.erb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Writer <%= @name %>>
Statement "<%= @statement %>"
<% if @storerates -%>
<% unless @storerates.nil? -%>
StoreRates <%= @storerates %>
<% end -%>
</Writer>
4 changes: 2 additions & 2 deletions templates/plugin/rrdcached.conf.erb
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<Plugin rrdcached>
DaemonAddress "<%= @daemonaddress %>"
DataDir "<%= @datadir %>"
<% unless @createfiles -%>
<% unless @createfiles.nil? -%>
CreateFiles "<%= @createfiles %>"
<% end -%>
<% if @createfilesasync -%>
<% unless @createfilesasync.nil? -%>
CreateFilesAsync "<%= @createfilesasync %>"
<% end -%>
<% if @stepsize -%>
Expand Down
2 changes: 1 addition & 1 deletion templates/plugin/sensors.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
Sensor "<%= @sensor %>"
<% end -%>
<% end -%>
<% if @ignoreselected -%>
<% unless @ignoreselected.nil? -%>
IgnoreSelected "<%= @ignoreselected %>"
<% end -%>
</Plugin>
8 changes: 4 additions & 4 deletions templates/plugin/statsd.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@
<% if @port -%>
Port <%= @port %>
<% end -%>
<% if @deletecounters -%>
<% unless @deletecounters.nil? -%>
DeleteCounters <%= @deletecounters %>
<% end -%>
<% if @deletetimers -%>
<% unless @deletetimers.nil? -%>
DeleteTimers <%= @deletetimers %>
<% end -%>
<% if @deletegauges -%>
<% unless @deletegauges.nil? -%>
DeleteGauges <%= @deletegauges %>
<% end -%>
<% if @deletesets -%>
<% unless @deletesets.nil? -%>
Deletesets <%= @deletesets %>
<% end -%>
<% if @timerpercentile -%>
Expand Down
4 changes: 2 additions & 2 deletions templates/plugin/write_http.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
<% if values['password'] -%>
Password "<%= values['password'] %>"
<% end -%>
<% if values['verifypeer'] -%>
<% unless values['verifypeer'].nil? -%>
VerifyPeer "<%= values['verifypeer'] %>"
<% end -%>
<% if values['verifyhost'] -%>
<% unless values['verifyhost'].nil? -%>
VerifyHost "<%= values['verifyhost'] %>"
<% end -%>
<% if values['cacert'] -%>
Expand Down

0 comments on commit 385e9e7

Please sign in to comment.