1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Merge pull request #5047 from sergevanginderachter/synch_template_ansiblesshhost

synchronize: allow ansible_ssh_host to be templated
This commit is contained in:
jctanner 2014-01-02 09:05:14 -08:00
commit 99560e3902

View file

@ -69,6 +69,8 @@ class ActionModule(object):
# from the perspective of the rsync call the delegate is the localhost
src_host = '127.0.0.1'
dest_host = inject.get('ansible_ssh_host', inject['inventory_hostname'])
# allow ansible_ssh_host to be templated
dest_host = template.template(self.runner.basedir, dest_host, inject, fail_on_undefined=True)
dest_port = options.get('dest_port')
inv_port = inject.get('ansible_ssh_port', inject['inventory_hostname'])