在Amazon AWS上运行节点检查器 [英] Running Node Inspector on Amazon AWS

查看:123
本文介绍了在Amazon AWS上运行节点检查器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在亚马逊AWS上运行节点检查器。通过网络上的一系列不同的答案,很多小时后,我按照下列步骤操作:


  1. npm install -g node-检查员


  2. 从aws服务器运行node-inspector





    Node Inspector v0.12.5
    访问 http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858 开始调试。


  3. 运行ssh -i mypemkey.pem -L username @ amazonhost


  4. 从服务器运行节点--debug myapp



    返回:

    调试器侦听端口5858


  5. 我希望工作的网址不是我终于得到了这个

    127.0.0.1:5858/?ws=127.0.0.1:5858&port5858



    返回此



    类型:连接

    v8-Version:3.28.71.19

    协议版本:1

    嵌入主机:节点v0.12.7

    内容长度:0



$ b $我认为我很亲近我不明白调试器的工作原理。我在这里缺少什么?



感谢您的洞察。

解决方案

p>问题是操作顺序和错误的ssh信息
逐步获取节点检查器在amazon aws和大多数服务器上工作。

nodejs v0.12.7

node-inspector v.0.12.5



1.(在服务器上) - npm install -g node-inspector --save

2.(从我的本地命令窗口) - ssh -i [YourPemKey.pem] -L 8080:127.0.0.1:8080 username @ amazonDNS

3.(在服务器上) - 节点检查器
3.结果:Node Inspector v0.12.5
访问 http://127.0.0.1:8080/?ws=127.0.0:8080&port=5858

4.(在单独控制台的服务器上)node - 调试myApp.js



转到 http://127.0.0.1:8080/?ws=127.0.0.1:808 0& port = 5858


I am trying to run node-inspector on amazon AWS. Through a series of different answers on the web and many hours later I have followed these steps:

  1. npm install -g node-inspector

  2. ran "node-inspector" from the aws server

    Got Back:
    Node Inspector v0.12.5 Visit http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858 to start debugging.

  3. from my computer ran " ssh -i mypemkey.pem -L username@amazonhost

  4. ran node --debug myapp from the server

    Got Back:
    Debugger Listening on port 5858

  5. The url I expected to work did not but i finally got this
    127.0.0.1:5858/?ws=127.0.0.1:5858&port5858

    To return This

    Type:Connect
    v8-Version:3.28.71.19
    Protocol-Version: 1
    Embedding-Host: node v0.12.7
    Content-Length: 0

I think I am close. I do not understand how the debugger works exactly. What am I missing here?

Thank You for any insight.

解决方案

The problem was with the order of operations and the wrong ssh information Step by Step to get node-inspector working on amazon aws and probably most servers.
nodejs v0.12.7
node-inspector v.0.12.5

1.(on the server) - npm install -g node-inspector --save
2.(from my local command window) - ssh -i [YourPemKey.pem] -L 8080:127.0.0.1:8080 username@amazonDNS
3.(on the server) - node-inspector 3. Results in: Node Inspector v0.12.5 Visit http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858
4. (on the server in a separate console) node --debug myApp.js

Go to http://127.0.0.1:8080/?ws=127.0.0.1:8080&port=5858

这篇关于在Amazon AWS上运行节点检查器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆