Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Trust and Identity Incubator
mdx-saas-config
Commits
e91a0cdd
Commit
e91a0cdd
authored
Mar 31, 2022
by
Martin van Es
Browse files
Automatically download geoDNS database files
parent
78895277
Changes
3
Hide whitespace changes
Inline
Side-by-side
.gitignore
View file @
e91a0cdd
inventory/group_vars/geodns.yml
.ssh/id_*
README.md
View file @
e91a0cdd
...
...
@@ -25,3 +25,8 @@ During deploy, (Apache) virtualhost ServerNames will be generated by the followi
* proxy-[realm].[tld]
Make sure you have DNS entries for those hostnames in geoDNS configuration.
## geoDNS servers
To automatically download geoDNS GeoLite2DB's add a file ```
geodns.yml
``` to ```
inventory/group_vars
``` with the following content:
```
geodns_licence:
<your
license
key
>
```
roles/geodns/tasks/main.yml
View file @
e91a0cdd
...
...
@@ -62,15 +62,20 @@
notify
:
-
"
enable
geodns
job"
-
name
:
Copy
GeoLite2DB's
ansible.builtin.
copy
:
src
:
"
{{
item
}}
"
-
name
:
Download
GeoLite2DB's
ansible.builtin.
unarchive
:
src
:
"
https://download.maxmind.com/app/geoip_download?edition_id={{
item
}}&license_key={{
geodns_licence
}}&suffix=tar.gz
"
dest
:
"
{{
geolite_dir
}}"
mode
:
'
0644'
extra_opts
:
'
--strip-components=1'
remote_src
:
yes
with_items
:
-
GeoLite2-Country.mmdb
-
GeoLite2-ASN
-
GeoLite2-City
-
GeoLite2-Country
notify
:
-
"
enable
geodns
job"
when
:
geodns_licence is defined
-
name
:
Create geoDNS config
ansible.builtin.template
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment