blob: 2173adf5ceb9dd34fcfaebd67ffe8d1fc31754af (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
<%- | String $virtual_host,
String $target,
String $custom_config,
| -%>
# THIS FILE IS MANAGED BY PUPPET, MANUAL CHANGES WILL BE OVERWRITTEN AT THE
# NEXT PUPPET RUN.
server {
listen 80;
listen [::]:80;
listen 443 ssl;
listen [::]:443 ssl;
if ($https != "on") {
return 301 https://$host$uri;
}
ssl_certificate /etc/ssl/public/<%= $virtual_host %>.chain.pem;
ssl_certificate_key /etc/ssl/private/<%= $virtual_host %>.key.pem;
access_log /var/log/nginx/<%= $virtual_host %>.access.log;
error_log /var/log/nginx/<%= $virtual_host %>.error.log;
server_name <%= $virtual_hosts %>;
<%= $custom_config -%>
location / {
proxy_pass <%= $target %>;
}
}
|