Appearance
Python
安装 Python 。
查看版本。
python -V新建文件夹,进入文件夹。
mkdir test
cd test启动 http 服务,默认 8000 端口,可以设为 80 端口。
python -m http.server
python -m http.server 80新建文件 hello.html 。
<html>
<head>
<meta charset="utf-8">
<title>Hello</title>
</head>
<body>
<p>Hello World</p>
</body>
</html>访问 http://localhost/ ,显示 Directory listing 。
http.server 标准库,不建议生产环境使用。