This commit is contained in:
@@ -2,4 +2,9 @@
|
||||
- hosts: all
|
||||
tasks:
|
||||
- name: Ping hosts
|
||||
ansible.builtin.ping:
|
||||
ansible.builtin.ping:
|
||||
|
||||
- hosts: all
|
||||
roles:
|
||||
- testrole
|
||||
|
4
project/roles/testrole/tasks/main.yml
Normal file
4
project/roles/testrole/tasks/main.yml
Normal file
@@ -0,0 +1,4 @@
|
||||
- name: create test file
|
||||
ansible.builtin.template:
|
||||
src: testfile.j2
|
||||
dest: /tmp/testfile.txt
|
1
project/roles/testrole/templates/testfile.j2
Normal file
1
project/roles/testrole/templates/testfile.j2
Normal file
@@ -0,0 +1 @@
|
||||
this is testfile.txt on {{ inventory_hostname }}
|
Reference in New Issue
Block a user