I'm looking for a way to add (S)FTP support to my Drupal Commerce website.

It's rather simple. Once every night, a cron job should get all the files from the (S)FTP, process them and place other files back on the server. That's it :)

It's a store and all the products, customers and other data come from a different system. So the Feeds module should connect to the FTP and process the files.
But it looks like there is no decent FTP module around. I've looked into the Backup and Migrate, Storage API, Order FTP Export and Save to FTP, but nothing really met my requirements.

So is there an easy way to connect to an (S)FTP server and exchange files?

1 Answer 1


I think you better face this problem using system commands that adding FTP support to the Drupal stack.

For this you can use:

1) standard FTP. You can read here how to automate FTP commands from a bash script: http://www.stratigery.com/scripting.ftp.html

2) SFTP, FTP over SSH. If you can use SSH public key authentication this is the best way as you only will have to exec this command every day:

scp your-remote-user@your-remote-server:/path/to/files/* /local/dir/for/files

Once your files are copied locally you only have to process them with Feeds.

You can even use PHP exec and launch the script that retrieves your data from the Drupal Cron.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.