Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # start with localhost as dummy target
- - hosts: localhost
- gather_facts: no
- vars_prompt:
- - name: target_host
- prompt: "Ziel Host FQDN (target_host=<fqdn1>[,<fqdn2>]): "
- private: no
- tasks:
- - add_host:
- name: "{{ item }}"
- groups: target_host_group
- with_items: "{{ target_host.split(',') }}"
- tags:
- - debug
- # now run playbook over target_host_group
- - hosts: target_host_group
- vars_files: defaults.yml
- vars:
- ansible_ssh_pass: superawesomepwd # default password for user, as there is no ssh-key yet
- ansible_user: user
Advertisement
Add Comment
Please, Sign In to add comment