Outgoing FTP request from Google appengine using python

I need to make an outgoing ftp request to get some small files. There are 6 files, each less than 10K, and I only need to extract them once every couple of hours.

When I try to do this using urllib2.urlopen (" ftp://xxx.xxx.xxx "), I get an AttributeError exception: the 'module' object does not have the 'Ftp_port' attribute.

I have read the documentation and see that you are allowed to make http and https requests from the application, unfortunately, my application must consume ftp data, does this mean that I can’t use the application at all? I sincerely hope not.

So has anyone else found a way to make ftp requests, possibly with a paid account? And if not what other people have chosen? azure or ec2 allow outgoing ftp requests?

+3
source share
3 answers

You're right. Google App Engine does not allow FTP requests. Even with a paid account.

I had to use a LAMP instance on EC2 that processes FTPs through CURL and makes HTTP requests to it from GAE.

+5
source

, ; , EC2 FTP, . , 9 (SDK 1.7.7) . (, FTP) .

API Sockets (Python): https://developers.google.com/appengine/docs/python/sockets/

+2

drivehq.com is another option. It provides as a web + ftp server. So the third party I needed to interact with (which spoke only with FTP) was uploading files via FTP. And then I would sketch them on appengine.

0
source

Source: https://habr.com/ru/post/1762206/


All Articles