I want to upload files to Google App engine blobstore, is there any method that we can upload pdf files to google app engine blobstore through simple python script. I have a server on which due to some reasons i cannot install google app engine sdk , so what method should i use to upload files in blobstore.
2
-
If you can put a python script on the server, then you can put the SDK on the server (unless a policy says you can create python programs but not use thirds party libraries.) There is no installation required as such for the SDK. However you should use GCS as blobstore is being depricated.Tim Hoffman– Tim Hoffman2013-06-20 09:03:30 +00:00Commented Jun 20, 2013 at 9:03
-
Found the solution from this post ! stackoverflow.com/questions/17294507/…Omair Shamshir– Omair Shamshir2013-07-03 13:20:59 +00:00Commented Jul 3, 2013 at 13:20
Add a comment
|
2 Answers
Found method to upload files to blobstore programatically from this post :
Google App Engine - Error uploading file to blobstore from Python code
Comments
You can't upload directly to Blobstore. However if you use Google Cloud Storage instead, you can upload directly with the gsutil utility. You can access files in GCS from your App Engine application just as easily as with Blobstore.
3 Comments
Omair Shamshir
if i get the upload url from the GAE server and then do a POST Request at that url wouldn't it work ? however in this method the problem is how to send file in same format as the GAE does
Faisal
Yes it would work, i've done something similar through my android app. create a blobsture url and post a file following the multipart-form upload rfc standards.
Omair Shamshir
Thanks Faisal, i have figured out a way to do it in python also