mirror of
https://github.com/pikami/mail-server.git
synced 2024-11-25 19:35:42 +00:00
28 lines
616 B
Plaintext
28 lines
616 B
Plaintext
|
server "{{ inventory_hostname }}" {
|
||
|
listen on * port 80
|
||
|
location "/.well-known/acme-challenge/*" {
|
||
|
root "/acme"
|
||
|
request strip 2
|
||
|
}
|
||
|
location * {
|
||
|
block return 302 "https://$HTTP_HOST$REQUEST_URI"
|
||
|
}
|
||
|
}
|
||
|
|
||
|
{% for vhost in mx1_domains %}
|
||
|
server "{{ vhost }}" {
|
||
|
listen on * tls port 443
|
||
|
tls {
|
||
|
certificate "/etc/ssl/{{ vhost }}.fullchain.pem"
|
||
|
key "/etc/ssl/private/{{ vhost }}.key"
|
||
|
}
|
||
|
location "/.well-known/acme-challenge/*" {
|
||
|
root "/acme"
|
||
|
request strip 2
|
||
|
}
|
||
|
location * {
|
||
|
root "/vhosts/{{ vhost }}"
|
||
|
}
|
||
|
}
|
||
|
{% endfor %}
|