mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
27 lines
672 B
Text
27 lines
672 B
Text
{% set domain_ip_map = sni_forward_list.split(',') %}
|
|
stream {
|
|
|
|
map $ssl_preread_server_name $name {
|
|
{% for domain_ip in domain_ip_map %}
|
|
{{ domain_ip.split(":")[0] }} {{ domain_ip.split(":")[0].replace('.', '_') }};
|
|
{% endfor %}
|
|
default https_default_backend;
|
|
}
|
|
|
|
{% for domain_ip in domain_ip_map %}
|
|
upstream {{ domain_ip.split(":")[0].replace('.', '') }} {
|
|
server {{ domain_ip.split(":")[1] }}:443;
|
|
}
|
|
{% endfor %}
|
|
|
|
upstream https_default_backend {
|
|
server 127.0.0.1:443;
|
|
}
|
|
|
|
server {
|
|
listen 443;
|
|
listen [::]:443;
|
|
proxy_pass $name;
|
|
ssl_preread on;
|
|
}
|
|
}
|