diff --git a/lsyncd.sh b/lsyncd.sh index 4be6abf..7c3de7e 100644 --- a/lsyncd.sh +++ b/lsyncd.sh @@ -11,18 +11,27 @@ default.rsync, source = $(echo '"/var/www/html/wp"'), target = $(echo '"103.23.20.132:/var/www/html/wp"'), -} -sync { - default.rsync, - source = $(echo '"/etc/nginx/conf.d/"'), - target = $(echo '"103.23.20.132:/etc/nginx/conf.d/"'), -} + rsync = { update = true, perms = true, owner = true, group = true, rsh = $(echo '"/usr/bin/ssh -l root -i /root/.ssh/id_rsa"'), +} +} +sync { + default.rsync, + source = $(echo '"/etc/nginx/conf.d/"'), + target = $(echo '"103.23.20.132:/etc/nginx/conf.d/"'), + +rsync = { + update = true, + perms = true, + owner = true, + group = true, + rsh = $(echo '"/usr/bin/ssh -l root -i /root/.ssh/id_rsa"'), +} }" > /etc/lsyncd.conf; echo "Mencoba melakukan restart service lsycnd !"