set defaults

This commit is contained in:
rene
2022-03-17 19:01:51 +01:00
parent 57f0333e8a
commit 24a9487730

View File

@@ -6,7 +6,7 @@ map $http_upgrade $connection_upgrade {
server {
listen 80;
listen [::]:80;
server_name {{ mastodon_host }};
server_name {{ mastodon_host | default('{{ ansible_fqdn }}') }};
# Useful for Let's Encrypt
location /.well-known/acme-challenge/ { allow all; }
@@ -24,8 +24,8 @@ server {
ssl_session_cache shared:SSL:10m;
{% if disable_letsencrypt != "true" %}
ssl_certificate /etc/letsencrypt/live/{{ mastodon_host }}/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/{{ mastodon_host }}/privkey.pem;
ssl_certificate /etc/letsencrypt/live/{{ mastodon_host | default('{{ ansible_fqdn }}') }}/fullchain.pem;
ssl_certificate_key /etc/letsencrypt/live/{{ mastodon_host | default('{{ ansible_fqdn }}') }}/privkey.pem;
{% endif %}
keepalive_timeout 70;