sync host

This commit is contained in:
Emmanuel Garette 2019-02-25 11:56:15 +01:00
parent b06123cc04
commit 4c7ebd5d27

View File

@ -44,8 +44,7 @@ function sync_host()
{
CMD="onehost"
OPT="sync -f --rsync"
AUTH=$(get_one_auth)
res=$(su - oneadmin -c "${CMD} ${OPT} --user ${AUTH%:*} --password ${AUTH#*:}")
res=$(su - oneadmin -c "${CMD} ${OPT}")
if [[ ${?} -ne 0 ]]
then
error "Hosts sync failed"