Added basic setup for master and certification material

This commit is contained in:
2022-04-27 16:02:08 +02:00
parent 5f1ddaa73d
commit 2feefe0fd0
66 changed files with 2364 additions and 6 deletions

21
etchostsupdate.yaml Normal file
View File

@@ -0,0 +1,21 @@
---
- name: "generate /etc/hosts.ansible file"
template: "src=templates/etchosts.j2 dest='/etc/hosts.ansible' owner=root group=root mode=0644"
tags: etc_hosts
become: true
- name: "check if debian generated hosts file has a backup"
stat: "path=/etc/hosts.debian"
tags: etc_hosts
register: etc_hosts_debian
- name: "backup debian generated /etc/hosts"
command: "cp /etc/hosts /etc/hosts.debian"
when: etc_hosts_debian.stat.islnk is not defined
tags: etc_hosts
become: true
- name: "install /etc/hosts.ansible file"
command: "cp /etc/hosts.ansible /etc/hosts"
tags: etc_hosts
become: true