From 320dbb6de55e01e0750803a9147b9493c710699b Mon Sep 17 00:00:00 2001 From: Frank Brehm Date: Mon, 28 Mar 2016 22:05:55 +0200 Subject: [PATCH] Adding resolver/nexunus.sls, adding location information --- common.sls | 20 ++++++++++++++++++++ resolver/nexunus.sls | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 53 insertions(+) create mode 100644 resolver/nexunus.sls diff --git a/common.sls b/common.sls index fd7f741..b8c5c9e 100644 --- a/common.sls +++ b/common.sls @@ -14,3 +14,23 @@ networking: has_public_ipv6: False {%- endif %} +location: +{%- if salt['grains.get']('fqdn') == 'ns3.uhu-banane.de' %} + provider: gridscale +{%- elif salt['grains.get']('fqdn') in ('liz.nexunus.net', ) %} + provider: hetzner +{%- else %} + provider: profitbricks +{%- endif %} +{%- if salt['grains.get']('fqdn') == 'ns2.uhu-banane.de' %} + country: us +{%- else %} + country: de +{%- endif %} +{%- if salt['grains.get']('fqdn') == 'ns2.uhu-banane.de' %} + dc: pb-las +{%- elif salt['grains.get']('fqdn') == 'ns1.uhu-banane.de' %} + dc: pb-fra +{%- else %} + dc: unknown +{%- endif %} diff --git a/resolver/nexunus.sls b/resolver/nexunus.sls new file mode 100644 index 0000000..2a50eed --- /dev/null +++ b/resolver/nexunus.sls @@ -0,0 +1,33 @@ +{%- if salt['grains.get']('fqdn') in ('liz.nexunus.net', ) -%} + {%- set has_public_ipv6 = True -%} +{%- else -%} + {%- set has_public_ipv6 = False -%} +{%- endif -%} + +resolver: + default-nameserver: + - 8.8.8.8 + - 8.8.4.4 +{%- if has_public_ipv6 %} + - 2001:4860:4860::8888 +{%- endif %} + domain: nexunus.net + nameserver: +{%- if salt['grains.get']('fqdn') == 'liz.nexunus.net' %} + - 127.0.0.1 +{%- else %} + - 172.31.0.1 +{%- if has_public_ipv6 %} + - 2a01:4f8:171:3006:1000::1 +{%- endif %} +{%- endif %} + - 185.48.118.128 + - 185.102.95.107 +{%- if has_public_ipv6 %} + - 2a06:2380:0:1::3a +{%- endif %} + search: + - nexunus.net + - nexunus.de + - nexunus.com + -- 2.39.5