ansible-role-bind/tasks/keys.yml

24 lines
708 B
YAML
Raw Normal View History

2018-10-07 10:57:36 +00:00
- name: copy private key
2017-10-08 12:55:01 +00:00
copy:
2018-10-07 10:57:36 +00:00
dest: '/etc/bind/keys/K{{ item.0 }}.+{{ "00{}".format(bind_dnssec[item.0][item.1].algorithm)[-3:] }}+{{ bind_dnssec[item.0][item.1].tag }}.private'
content: '{{ bind_dnssec[item.0][item.1].private_key }}'
2017-10-08 12:55:01 +00:00
owner: root
group: bind
mode: 0640
2018-10-07 10:57:36 +00:00
# no_log: true
2017-10-08 12:55:01 +00:00
with_nested:
2018-10-07 10:57:36 +00:00
- '{{ bind_dnssec }}'
- [ 'ksk', 'zsk' ]
2017-10-08 12:55:01 +00:00
2018-10-07 10:57:36 +00:00
- name: copy public key
template:
src: public.key.j2
dest: '/etc/bind/keys/K{{ item.0 }}.+{{ "00{}".format(bind_dnssec[item.0][item.1].algorithm)[-3:] }}+{{ bind_dnssec[item.0][item.1].tag }}.key'
2017-10-08 12:55:01 +00:00
owner: root
group: bind
mode: 0640
2018-10-07 10:57:36 +00:00
# no_log: true
2017-10-08 12:55:01 +00:00
with_nested:
2018-10-07 10:57:36 +00:00
- '{{ bind_dnssec }}'
- [ 'ksk', 'zsk' ]