I want to copy files using rsync
over ssh, but a "Cannot execute command-line and remote command." is raised, meanwhile it works fine with scp
.
Command : rsync -ravh folder XXX:folder
My ssh config is configured as follows :
Host XXX
Hostname YY
User user
RequestTTY yes
RemoteCommand bash --init-file ~/.bashrc
I noticed that by removing the RemoteCommand
option, rsync does the job.
How could I manage to make rsync work while using my current ssh host config ?
Thanks in advance.