|
From: Daniel B. <da...@fi...> - 2017-06-16 11:17:06
|
Le 16/06/2017 à 05:13, Craig Barratt via BackupPC-users a écrit :
> You can set $Conf{RsyncSshArgs} to a command that simply executes its
> arguments (like ssh does). However, rsync adds the host name to
> whatever you specify in $Conf{RsyncSshArgs}, so unfortunately this
> doesn't work since the first argument is the host name, and env will
> give an error:
>
> $Conf{RsyncSshArgs} = ['-e', '/usr/bin/env']; # <- this doesn't
> work
>
> A very bad hack would be to use something like this:
>
> $Conf{RsyncSshArgs} = ['-e', '/usr/bin/sudo -p'];
>
> (sudo has to be passwordless from the BackupPC user.) The -p (prompt)
> option expects an argument to set the password prompt (which is not
> used). So it consumes the host name argument appended by rsync, then
> runs the rest of the command like ssh does. Bingo - the client rsync
> gets run locally, with elevated privileges from sudo, without ssh.
>
Thanks Craig, I'll try ASAP this :-)
++
--
Logo FWS
*Daniel Berteaud*
FIREWALL-SERVICES SAS.
Société de Services en Logiciels Libres
Tel : 05 56 64 15 32 <tel:0556641532>
Visio : http://vroom.fws.fr/dani
/www.firewall-services.com/
|