fetch
Collection: builtin
Full Name: parallax.builtin.fetch
Aliases: ansible.builtin.fetch, fetch
Synopsis
Copy files from remote hosts back to the controller
Parameters
| Name | Type | Required | Default | Description |
|---|---|---|---|---|
| src | string | yes | The file to fetch from the remote system | |
| dest | string | yes | A directory to save the file into | |
| fail_on_missing | bool | true | Makes it fail when the source file is missing | |
| validate_checksum | bool | true | Verify that the source and destination checksums match | |
| flat | bool | false | Allows you to override the default behavior of appending hostname/path/to/file to the destination |
Example
- name: Collect each host's kernel log
fetch:
src: /var/log/kern.log
dest: /tmp/collected/
flat: false