main.yml 457 Bytes
---
# tasks file for yoho.dns


# make sure user type DNS
- name: "make sure user type DNS to confirm"
  fail:
    msg: "user do not type DNS"
  when: confirmation != 'DNS'


- name: get current time
  set_fact:
     timestamp: "{{ lookup('pipe','date +%Y-%m-%d-%H-%M-%S') }}"
     zone_serical: "{{ ansible_date_time.epoch }}"

- name:  sync bind9 zone files
  template:
    src: qcloud.zone.j2
    dest: /Data/named/qcloud.zone
  notify:
    - reload bind