summaryrefslogtreecommitdiff
path: root/ansible-practice/06-playbook-create-multiple-files.yml
diff options
context:
space:
mode:
authorboom2 <blizzack@blizzack.com>2023-11-21 14:11:56 -0500
committerboom2 <blizzack@blizzack.com>2023-11-21 14:11:56 -0500
commit62766cf1fd721d278e95821e05e6b41f7888eed5 (patch)
tree35c0866b9dbc09cdc695435a3aa6aa1424cac1a4 /ansible-practice/06-playbook-create-multiple-files.yml
initial commit
Diffstat (limited to 'ansible-practice/06-playbook-create-multiple-files.yml')
-rw-r--r--ansible-practice/06-playbook-create-multiple-files.yml19
1 files changed, 19 insertions, 0 deletions
diff --git a/ansible-practice/06-playbook-create-multiple-files.yml b/ansible-practice/06-playbook-create-multiple-files.yml
new file mode 100644
index 0000000..3a6284b
--- /dev/null
+++ b/ansible-practice/06-playbook-create-multiple-files.yml
@@ -0,0 +1,19 @@
+# create multiple empty files
+# https://phoenixnap.com/kb/ansible-create-file
+
+---
+- name: "06 - Playing with Ansible - create multiple empty files"
+ hosts: all
+# hosts: localhost
+# connection: local
+ tasks:
+ - name: Create multiple files
+ file:
+ path: "~/{{ item }}"
+ state: touch
+ with_items:
+ - ansible_created_file-03.txt
+ - ansible_created_file-04.txt
+ - ansible_created_file-05.txt
+ - ansible_created_file-06.txt
+... \ No newline at end of file