ansible_mitogen: Allow mitogen_fetch to bypass slurp module
This reapplies an earlier change, when this plugin was first introduced to Mitogen. The plugin was updated to fix [DEPRECATION WARNING]: The '_remote_checksum()' method is deprecated. I've elected to short-circuit the if statemtn logic, rather than deleting/unindenting, to make the code delta much smaller. This should make it easier to maintain/update. Fixes #915pull/923/head
parent
0ff9c6e579
commit
25ea6dde02
@ -1,23 +1,32 @@
|
|||||||
# issue #615: 'fetch' with become: was internally using slurp.
|
# issue #615: 'fetch' with become: was internally using slurp.
|
||||||
|
|
||||||
- hosts: target
|
- hosts: test-targets
|
||||||
any_errors_fatal: True
|
any_errors_fatal: True
|
||||||
gather_facts: no
|
gather_facts: no
|
||||||
|
# Without Mitogen this causes Ansible to use the slurp module, which is *slow*
|
||||||
become: true
|
become: true
|
||||||
vars:
|
vars:
|
||||||
mitogen_ssh_compression: false
|
mitogen_ssh_compression: false
|
||||||
tasks:
|
tasks:
|
||||||
- shell: |
|
- block:
|
||||||
dd if=/dev/zero of=/tmp/512mb.zero bs=1048576 count=512;
|
- shell: |
|
||||||
chmod go= /tmp/512mb.zero
|
dd if=/dev/zero of=/tmp/512mb.zero bs=1048576 count=512;
|
||||||
|
chmod go= /tmp/512mb.zero
|
||||||
|
|
||||||
- fetch:
|
- fetch:
|
||||||
src: /tmp/512mb.zero
|
src: /tmp/512mb.zero
|
||||||
dest: /tmp/fetch-out
|
dest: /tmp/fetch-out
|
||||||
|
|
||||||
- file:
|
- file:
|
||||||
path: /tmp/fetch-out
|
path: /tmp/512mb.zero
|
||||||
state: absent
|
state: absent
|
||||||
delegate_to: localhost
|
|
||||||
|
- file:
|
||||||
|
path: /tmp/fetch-out
|
||||||
|
state: absent
|
||||||
|
delegate_to: localhost
|
||||||
|
run_once: true
|
||||||
|
when:
|
||||||
|
- is_mitogen
|
||||||
tags:
|
tags:
|
||||||
- issue_615
|
- issue_615
|
||||||
|
Loading…
Reference in New Issue