Interface with a SFTP Server¶
The communication with an SFTP server is automated with a couple integration scripts.
Send a File from a Waarp R66 Instance to a SFTP Server¶
In this scenario, the file follows the following path:
Put a file named
tosftp.file
in the “out” folder of the instanceserver1
(/var/lib/waarp/server1/out
). For example, use the commandcp /var/lib/waarp/files/test1.file /var/lib/waarp/server1/out/tosftp.file
Start the transfer with the command:
waarp-r66client server1 send -file tosftp.file -to server2 -rule toSFTP
The file is sent to
server2
, which forwards it togwftp
, before it is sent to the local SFTP server by running the command /usr/share/waarp/r66-sftp.sh as a post-transfer task.Once all transfers are done, the file is available in the “in” folder of the SFTP server (
/var/lib/waarp/ftp/sftp/in
).
Get a File from a SFTP Server¶
In this scenario, the file follows the following path:
Put a file named
fromsftp.file
in the “out” folder of the local SFTP server (/var/lib/waarp/ftp/sftp/out
). For example, use the commandcp /var/lib/waarp/files/test1.file /var/lib/waarp/ftp/sftp/out/fromsftp.file
Start the transfer with the command:
/usr/share/waarp/sftp-r66.sh fromsftp.file
It fetches the file from the local SFTP server and automatically forwards it to the destination instance
server1
.Once all transfers are done, the file is available in the “in” folder of
server1
(/var/lib/waarp/server1/in
).