How to execute shell commands on a remote server and get the output of the commands in symfony?

I have a local machine running a symfony website which basically acts as an interface for the remote Linux (RHEL) server (SSH access)

I am trying using symfony to execute Linux commands on the remote server and get the output of the commands.

Any help would be appreciated.

Have you looked into the symfony/process component?

Yeah i looked for it but the problem is that the process component will use windows shell as i am working with symfony on a windows machine but i need to get the output of linux commands not windows shell.

you’ll always have to start from the windows shell. a quick google search hints that the PTY setting may be of use here.

Sorry, I didn’t get it. How can i use symfony process component with PTY?

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.