Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Ubuntu install http-server

2025-01-15 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

1) install the NPM package manager

Apt-get install npm

2) install nodejs package manager

Apt-get install nodejs

3) run npm to install http-server

Npm install http-server-g

Prompt error

/ usr/bin/env: node: No such file or directory

Reason

Because npm is executed using / usr/bin/node by default, but there is no / usr/bin/node locally, you need to create a soft link to the real nodejs and execute the following instructions

Ln-s / usr/bin/nodejs / usr/bin/node

4) start http-server under the html path of janus-gateway

Root@4c9f329b2677:/home/dong/janus-src/janus-gateway/html# http-server

Starting up http-server, serving. /

Available on:

Http://127.0.0.1:8080

Http://172.18.0.13:8080

Hit CTRL-C to stop the server

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report