Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Run Perl script on remote server

by daxim (Chaplain)
on Feb 14, 2013 at 16:01 UTC ( #1018750=note: print w/ replies, xml ) Need Help??


in reply to Run Perl script on remote server

Simple: open a pipe to ssh.

Or run your Perl programs in a Web server, and write a PHP HTTP client for them (fopen, curl).

If that is not possible or sufficient, then you're looking for RMI/distributed computing (or conceptionally equivalent). If you have no idea where to start, simply run a Perl SOAP server and PHP SOAP client, SOAP sucks hairy donkey balls but at least it's painless in PHP. There are many more protocols (XML-RPC, JSON-RPC, Corba, ) and you can invent your own protocol (on top of sockets, on top of HTTP, ).


Comment on Re: Run Perl script on remote server
Replies are listed 'Best First'.
Re^2: Run Perl script on remote server
by tmharish (Friar) on Feb 14, 2013 at 18:03 UTC
    Or run your Perl programs in a Web server, and write a PHP HTTP client for them (fopen, curl).

    I did that once and it works very well - POST and GET values can be passed on as is and the testing can be done on the server with Perl while completely ignoring the one with PHP ( Server A ).

    The only downsides are:

    • Cross domain scripts sometimes give the user a scary error
    • The browser will render nothing until the entire HTML is thrown out which might make page loads appear slow to the user - You cant flush STDOUT halfway to get the browser to start rendering stuff.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1018750]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (19)
As of 2015-07-29 15:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (265 votes), past polls