I am a happy user of rsync -e ssh and use it to synchronize data between my machine and a remote host using
rsync -avz -e ssh me@hostA:~/folder ~/folder
And this did what I needed until now.
I am now working with a configuration where the access is a bit more complicated. Suppose now ~/folder is on hostB, but hostB is not directly accessible from my machine, but only indirectly via hostA.
So if I only want to see the folder on hostB. I first need to ssh to hostA, then to hostB after which I can see my files in ~/folder on the remote host.
My question now is, what is the (best) method to use rsync directly between my machine and hostB?
Unfortunately this is the configuration I need to work with. Assume there is no possibility to temporarily store the data on hostA itself.