diff --git a/holmium.yml b/holmium.yml index 753092b..1eafa29 100644 --- a/holmium.yml +++ b/holmium.yml @@ -11,22 +11,26 @@ ingress: - server: kant hosts: - - jabber.n39.eu - - conference.jabber.n39.eu - - spaceapi.n39.eu + - name: jabber.n39.eu + - name: conference.jabber.n39.eu + - name: spaceapi.n39.eu - server: krypton hosts: - - entities.svc.n39.eu + - name: entities.svc.n39.eu - server: pottwal hosts: - - gitea.n39.eu - - uritools.n39.eu - - entities-validation.svc.n39.eu - - sl.n39.eu - - pad.n39.eu - - brotherql-web.n39.eu + - name: gitea.n39.eu + - name: uritools.n39.eu + - name: entities-validation.svc.n39.eu + - name: sl.n39.eu + - name: pad.n39.eu + - name: brotherql-web.n39.eu + local: true - server: radon hosts: - - nodered.n39.eu - - rabbitmq.n39.eu - - pwr-meter-pulse-gw-19i.svc.n39.eu + - name: nodered.n39.eu + local: true + - name: rabbitmq.n39.eu + local: true + - name: pwr-meter-pulse-gw-19i.svc.n39.eu + local: true diff --git a/roles/nginx-https-ingress/templates/dehydrated-host.conf.j2 b/roles/nginx-https-ingress/templates/dehydrated-host.conf.j2 index 7647271..ac670b6 100644 --- a/roles/nginx-https-ingress/templates/dehydrated-host.conf.j2 +++ b/roles/nginx-https-ingress/templates/dehydrated-host.conf.j2 @@ -4,7 +4,7 @@ server { listen 80; listen [::]:80; - server_name {{ host }}; + server_name {{ host.name }}; location /.well-known/acme-challenge { proxy_pass http://{{ item.server }}.n39.eu:80; diff --git a/roles/nginx-https-ingress/templates/passthrough.conf.j2 b/roles/nginx-https-ingress/templates/passthrough.conf.j2 index b5deb41..46e05f4 100644 --- a/roles/nginx-https-ingress/templates/passthrough.conf.j2 +++ b/roles/nginx-https-ingress/templates/passthrough.conf.j2 @@ -5,7 +5,9 @@ stream { {% for i in ingress %} {% if 'hosts' in i %} {% for host in i.hosts %} - {{ host }} {{ i.server }}; +{% if host.local is not defined or host.local == False %} + {{ host.name }} {{ i.server }}; +{% endif%} {% endfor %} {% endif %} {% endfor %}