1602 / roco

Deploy app to remote server via ssh, inspired by capistrano

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Do not close connection between commands

rodrigok opened this issue · comments

There are some way to not close ssh connection between sequential commands?

Closing connection between this commands make the execution be slow. I think is because this way is executed the connection negotiation for every single command.

I briefly investigated this when started building roco, but found nothing. If you know something - please share.

On Wed, Dec 18, 2013 at 12:50 AM, Rodrigo K Nascimento
notifications@github.com wrote:

There are some way to not close ssh connection between sequential commands?

Closing connection between this commands make the execution be slow. I think is because this way is executed the connection negotiation for every single command.

Reply to this email directly or view it on GitHub:
#4

@anatoliychakkaev The solution is to use library that supports it. Or just join commands with &&.
For example, https://github.com/1602/roco/blob/master/lib/rockout.js#L174 can be rewrited with https://github.com/mscdex/ssh2#examples