I would like to know if it's possible to handle interactive commands.
Currently, if any command ask for keyboard input, a password for example, page reload last forever, until a browser/server timeout is reached.
Any hint will be welcome, as I could try to test/implement by myself.
Thanks.
Hi,
No, that is not possible with PHPshell.
There exists another open source project "shellinabox" (https://code.google.com/p/shellinabox/) where you can work interactively.
Best regards, Wolfgang
Thanks for the link, but I would need a solution for a shared web hosting.
Would it be possible a simple version with a predefined text input?
I mean, if I just need to run a command that needs a password, give that password to executed process input on demand.
For example, I am trying to execute a git push, but using a ssh with password.
You can use I/O-redirects or pipes for providing input for commands in PHP shell ("command <inputfile" or "echo input | command").
If a command really wants keyboard input (e.g. entering a password), expect (https://en.wikipedia.org/wiki/Expect) can solve your problem.
Best regards, Wolfgang
Close ticket, thats not possible with phpshell, alternatives were mentioned.