http-server
Simple static HTTP server to serve static files. More information: https://github.com/http-party/http-server.
- Start an HTTP server listening on the default port to serve the current directory:
http-server
- Start an HTTP server on a specific port to serve a specific directory:
http-server
- Start an HTTP server using basic authentication:
http-server --username --password
- Start an HTTP server with directory listings disabled:
http-server -d
- Start an HTTPS server on the default port using the specified certificate:
http-server
- Start an HTTP server and include the client's IP address in the output logging:
http-server --log-ip
- Start an HTTP server with CORS enabled by including the
Access-Control-Allow-Origin: *header in all responses:
http-server --cors
- Start an HTTP server with logging disabled:
http-server
来源:tldr-pages contributors · 作者与贡献记录 · CC BY 4.0。离线整理了版式、链接和媒体显示。
