From 5a96193d75147751b4933ab6e60a1df3ebf6b392 Mon Sep 17 00:00:00 2001 From: discopatrick Date: Tue, 12 Jul 2016 13:10:17 +0100 Subject: [PATCH] adds example of setting a delegate host with a var --- playbooks/rsync.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/playbooks/rsync.yml b/playbooks/rsync.yml index 5c5306a..a4785b0 100644 --- a/playbooks/rsync.yml +++ b/playbooks/rsync.yml @@ -26,3 +26,8 @@ # mode: push ## default is push delegate_to: ansible-pocs-2 + - name: sync remote folders using var as delegate + synchronize: + src: /home/admin/syncthis + dest: /home/admin + delegate_to: "{{ groups['staging'][1] }}"