Complete overkill, but fun to learn and play with..
Basic steps:
- Install NiFi
- Secure NiFi (see NiFi Toolkit for home use)
- Create process group for the transfer
- Drag "ListSFTP" to the canvas, set host, port, user, pass.
- Drag "FetchSFTP" to the canvas, set host, port, user, pass.. set remote file to ${path}/{file}
Also set the settings tab to terminate the relationship for everything except success. - Drag "PutFile" to the canvas, set directory to put the files in.
On the settings tab, click the terminate boxes for both Success and Failure.
(Alternately you cansend to SFTP or other destinations) - Drag the arrow from ListSFTP to FetchSFTP and set it to Success when prompted.
- Drag the arrow from FetchSFTP to PutFile and set it to Success when propmted.
You can now start/stop/enable/disable individual steps or right click on the canvas and click start to bring them all to life.