Reputation: 110452
I have a number of ~10MB xml files on a local computer. For each file, I need to send it to a remote server for processing. The way I attempted to do this was by using curl
to POST to a function:
curl MyIP -d @my_file.xml
Where MyIP
is the url of the function that does the xml processing. However, this seems to be problematic, as most of the POST data is cut off due to some limitation (though I'm not sure what this limitation is).
What would be the suggested way to send a ~10MB file to a remote server for text processing? Could I set up the above way using curl & a function to work? Should I set up an FTP and then run a cron job on the folder?
Upvotes: 1
Views: 3612
Reputation: 66729
Use POST
curl -X POST -d @my_file.xml http://user:pass@myhost/
By default curl uses "GET" verb. You have to specify the HTTP verb using option -X
Upvotes: 1