zuul-jobs/roles/validate-zone-db/tasks/main.yaml
Ian Wienand e6ca2e7c84 validate-zone-db : add job and make more generic
There was a request in If3dc95d1348553e5b43683f6a36d324fb978fbed to
make the role more generic so it could handle different layouts of
zone.db files.  Make it so the role can take a list of tuples (domain,
path/to/zone.db) so that we can handle any layouts, and modify the
default searching to build this from the source directory.

Reviews in https://review.opendev.org/660888 suggested making this
defined as a generic job, so a validate-zone-db job is added.

Change-Id: I56cbc027f63787f90eef283eeb2fbb81486dcaf5
2019-05-24 10:00:49 +10:00

14 lines
295 B
YAML

- name: Install bind9utils
package:
name: bind9utils
state: present
become: yes
- name: Build zone.db list
include_tasks: find.yaml
when: not zone_db_files
- name: 'Run checkzone'
command: '/usr/sbin/named-checkzone {{ item[0] }} {{ item[1] }}'
loop: "{{ zone_db_files }}"