Python Linux系统管理与自动化运维

第一章 Python 生态工具

1.1 Python内置小工具

1.1.1 1秒钟启动一个下载服务器

1 python2中:
2 python -m SimpleHTTPServer
3 python3中:
4 python -m http.server
5 #快速启动一个web服务,如果没有Index页面,即为简易的ftp服务。
6 #执行上面的命令就会在 当前目录下 启动一个文件下载服务器,默认打开 8000 端口。 

猜你喜欢

转载自www.cnblogs.com/catinsky/p/9173455.html