-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yml
36 lines (32 loc) · 1.19 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: 'dns-check-action'
author: 'WikiTide Technology Team'
description: 'provides checking of zonefiles using gdnsd'
inputs:
geoip-directory:
description: 'Path where we should put the GeoIP2 Country Test database'
required: true
default: '/usr/share/GeoIP'
geoip-filename:
description: 'Name for the file with the GeoIP2 Country Test database'
required: true
default: 'GeoLite2-Country.mmdb'
runs:
using: "composite"
steps:
- name: Install gdnsd and wget
run: sudo apt-get update && sudo apt-get install -y gdnsd wget
shell: bash
- name: Create directory for the GeoIP2 Country Test database
run: sudo mkdir -p "$GEOIP2_PATH"
shell: bash
env:
GEOIP2_PATH: ${{ inputs.geoip-directory }}
- name: Download the GeoIP2 Country Test database
run: sudo wget "https://github.com/maxmind/MaxMind-DB/raw/e92ddde7128f928889ace232cebe8833182f599b/test-data/GeoIP2-Country-Test.mmdb" -O "$GEOIP2_PATH/$GEOIP2_FILENAME"
shell: bash
env:
GEOIP2_PATH: ${{ inputs.geoip-directory }}
GEOIP2_FILENAME: ${{ inputs.geoip-filename }}
- name: Run gdnsd checkconf
run: gdnsd -c . checkconf
shell: bash