在Ubuntu(18.04.1 LTS)AWS

时间:2018-10-05 13:02:43

标签: node.js mongodb ubuntu npm nodemon

我的AWS EC2实例上运行的是Ubuntu(18.04.1 LTS)Linux发行版。

我已经在该系统上安装了必要的NodeJS和NPM。我还配置了ReactJS在此系统上运行。以下是我的系统上当前可用的NodeJS版本的详细信息:

>node -v

输出:v6.0.0

>nodejs -v

输出:v10.11.0

>npm -v

Output: v6.4.1

现在,我正在此系统上设置MongoDB。为此,我已经安装了Mongo,并且工作正常。我还安装了“ nodemon”以自动启动“ server.js”。

但是现在当我运行命令nodemon时,它会提供以下输出:

ubuntu@/node$ nodemon
[nodemon] 1.18.4
[nodemon] to restart at any time, enter `rs`
[nodemon] watching: *.*
[nodemon] starting `nodemon ./server.js`
[nodemon] running an unsupported version of node v6.0.0
[nodemon] nodemon may not work as expected - please consider upgrading to LTS
[nodemon] 1.17.5
[nodemon] to restart at any time, enter `rs`
[nodemon] watching: *.*
[nodemon] starting `node ./server.js`
[nodemon] app crashed - waiting for file changes before starting...
rs
[nodemon] starting `nodemon ./server.js`
[nodemon] running an unsupported version of node v6.0.0
[nodemon] nodemon may not work as expected - please consider upgrading to LTS
[nodemon] 1.17.5
[nodemon] to restart at any time, enter `rs`
[nodemon] watching: *.*
[nodemon] starting `node ./server.js`
[nodemon] app crashed - waiting for file changes before starting...

最大的困惑是我无法弄清楚如何仅升级node版本而不升级nodejs版本。

有人可以帮助解决这个问题吗?

PS:我还希望如果我升级npmnode

时,我当前的ReactJS设置不受影响。

谢谢

0 个答案:

没有答案