increase local host performance for copy and template module

Hi all,

I'm having a performance issue with local execution of the copy and template modules that are put into task files. Both modules
are used in with_nested loops where item[0] is about 100 elements and item[1] is about 6 elements long for copy and 10 elements
long for template.

Execution of these tasks take about 15min which means that one loop execution is a little bit less than a second.

I've already tried to put the destination of the copy/template operation to /dev/shm but that didn't result in a speedup.

Any tips on how to increase performance for those modules?

I'm already using "connection: local" and "gather_facts: false", the host has an SSD and is running CentOS 7.5, Ansible 2.6.3.

Thanks,

  Uwe