Hi Barry,
On 15 May 2015 at 20:58, Barry Grumbine <[email protected]> wrote:
> Hi,
>
> I have never used sftp, but from the man page it looks like the sftp
> commands need to be in a separate file. Something like:
>
> fetch2.sh:
> #!/bin/sh
> sftp -b /home/jungle/batchfile jungle@host
>
> /home/jungle/batchfile:
> cd /home/jungle
> put file_*.csv aaa_completed
>

Ah, that's excellent! Thanks!!

>
> If it were me, I would just use scp in my crontab, something like:
>
> 0 1 * * * /usr/bin/scp /home/jungle/file_*csv jungle@host:/usr/home/jungle/
>

In my testing I'd be able to use scp or rsync but when I deploy, I'll
only have sftp available.

Thanks for trying this out and giving me input.

>
> ...or maybe rsync if the file is large.
>
>
> -Barry
>
>

Best,
j

Reply via email to