[英]Nodejs call shellscript or use native node modules?
I am new to node. 我是Node的新手。 I have the following requirement that can be broken down into three different parts 1) Pure nodejs: Get the IP and User info 2) SSH to a remote server with a private key and list down the directories
我有以下要求,可以分为以下三个部分:1)纯nodejs:获取IP和用户信息2)使用私钥通过SSH到远程服务器并列出目录
What is the best way to do it? 最好的方法是什么? I have thought of calling a shell script with child_process for the second step.
我已经考虑过在第二步中使用child_process调用shell脚本。 Is there a better way to do it?
有更好的方法吗?
我将使用node.js模块ssh2 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.