ansible-role-cmdb/tasks/server.yml

25 lines
749 B
YAML

---
- name: "Server | Write server startpage"
ansible.builtin.template:
src: servers.txt.j2
dest: "{{ cmdb.wiki_pages_path }}/servers.txt"
owner: "{{ cmdb.wiki_user }}"
group: "{{ cmdb.wiki_group }}"
mode: "0644"
- name: "Server | Write startpage for all servers"
ansible.builtin.template:
src: all.txt.j2
dest: "{{ cmdb.wiki_pages_path }}/servers/all.txt"
owner: "{{ cmdb.wiki_user }}"
group: "{{ cmdb.wiki_group }}"
mode: "0644"
- name: "Server | Write server item"
ansible.builtin.template:
src: item.txt.j2
dest: "{{ cmdb.wiki_pages_path }}/servers/all/{{ inventory_hostname }}.txt"
owner: "{{ cmdb.wiki_user }}"
group: "{{ cmdb.wiki_group }}"
mode: "0644"
tags: server_item