add file-creation-single.yml
This commit is contained in:
36
file-creation-single.yml
Normal file
36
file-creation-single.yml
Normal file
@ -0,0 +1,36 @@
|
||||
---
|
||||
- name: Create inventory based on passed extra_vars
|
||||
hosts: localhost
|
||||
gather_facts: no
|
||||
become: no
|
||||
|
||||
|
||||
vars:
|
||||
provision_host: "{{ tower_provision_host | default('localhost') }}"
|
||||
|
||||
|
||||
tasks:
|
||||
- name: "Create in-memory inventory for {{ provision_host }}"
|
||||
add_host:
|
||||
name: "{{ provision_host }}"
|
||||
groups:
|
||||
- remdiation
|
||||
|
||||
|
||||
# =========================================================================== #
|
||||
|
||||
|
||||
- name: Create a test file on remediation group
|
||||
hosts: remdiation
|
||||
gather_facts: no
|
||||
become: no
|
||||
|
||||
|
||||
tasks:
|
||||
- name: "Test #1 - Copy file to machine"
|
||||
copy:
|
||||
src : files/hello-ansible.txt
|
||||
dest : /tmp/hello-ansible.txt
|
||||
|
||||
|
||||
...
|
Reference in New Issue
Block a user