Fix scope of vhost template variable

Dynamic scoping for variables in ERB templates was removed in puppet
4[1], so look up the @serveradmin variable from the scope object.

[1] https://puppet.com/docs/puppet/4.10/lang_updating_manifests.html#dynamic-scoping-in-erb

Change-Id: Ia53125bed102193e149f995430bbdf10dfdbf428
This commit is contained in:
Colleen Murphy 2018-07-13 15:03:41 +02:00
parent 46bfc54912
commit d06c229268
1 changed files with 1 additions and 1 deletions

View File

@ -5,7 +5,7 @@
<% elsif @serveraliases -%>
<%= " ServerAlias #{@serveraliases}" %>
<% end %>
ServerAdmin <%= @serveradmin %>
ServerAdmin <%= scope.lookupvar("hound::serveradmin") %>
ErrorLog ${APACHE_LOG_DIR}/<%= scope.lookupvar("hound::vhost_name") %>-error.log