Skip to content

Commit b65114d

Browse files
committed
Fixup incorrect changes from merge
1 parent 003f415 commit b65114d

File tree

3 files changed

+4
-7
lines changed

3 files changed

+4
-7
lines changed

manifests/resource/vhost.pp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
# This definition creates a virtual host
44
#
55
# Parameters:
6-
# [*server_name*] - Server name (value to match in Host: header). Defaults to the resource's name.
76
# [*ensure*] - Enables or disables the specified vhost (present|absent)
87
# [*listen_ip*] - Default IP Address for NGINX to listen with this vHost on. Defaults to all interfaces (*)
98
# [*listen_port*] - Default IP Port for NGINX to listen with this vHost on. Defaults to TCP 80
@@ -41,7 +40,6 @@
4140
# ssl_key => '/tmp/server.pem',
4241
# }
4342
define nginx::resource::vhost(
44-
$server_name = $name,
4543
$ensure = 'enable',
4644
$listen_ip = '*',
4745
$listen_port = '80',

templates/vhost/vhost_location_directory.erb

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,9 @@
33
<%= key %> <%= value %>;
44
<% end -%><% end -%>
55
root <%= www_root %>;
6-
index <% index_files.each do |i| %> <%= i %> <% end %>;
7-
86
<% if has_variable?("try_files") then %>
97
try_files <% try_files.each do |try| -%> <%= try %> <% end -%>;
108
<% end %>
11-
129
index <% index_files.each do |i| %> <%= i %> <% end %>;
1310
<% if @location_cfg_append -%><% location_cfg_append.each do |key,value| -%>
1411
<%= key %> <%= value %>;

templates/vhost/vhost_ssl_header.erb

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
server {
22
listen <%= ssl_port %>;
3-
<% if ipv6_enable == 'true' && (defined? ipaddress6) %>listen [<%= ipv6_listen_ip %>]:<%= ipv6_listen_port %> default ipv6only=on;<% end %>
4-
server_name <%= server_name %>;
3+
<% if ipv6_enable == 'true' && (defined? ipaddress6) %>
4+
listen [<%= ipv6_listen_ip %>]:<%= ipv6_listen_port %> <% if @ipv6_listen_options %><%= ipv6_listen_options %><% end %> ipv6only=on;
5+
<% end %>
6+
server_name <%= rewrite_www_to_non_www ? name.gsub(/^www\./, '') : server_name.join(" ") %>;
57

68
ssl on;
79
ssl_certificate <%= ssl_cert %>;

0 commit comments

Comments
 (0)