一、安装系统
宿主机: macOS Mojave 10.14
虚拟机平台:Parallels Desktop 13 for Mac (安装过程略)
镜像: CentOS-7-x86_64-DVD-1810.iso
不折腾,和咸鱼有什么区别?
宿主机: macOS Mojave 10.14
虚拟机平台:Parallels Desktop 13 for Mac (安装过程略)
镜像: CentOS-7-x86_64-DVD-1810.iso
1 | # 安装 |
time.asctime([tuple])
time.clock()
1 | import time |
使用Time模块获取当前时间
1
2
3
4
5
6 import time()
time.time()
# 1470450851.211
time.strftime("%H:%M:%S")
# '10:35:26'
使用Datetime模块获取当前时间
1
2
3
4
5
6 # 获取一个datetime类型的时间
d = datetime.datetime.now()
# datetime.datetime(2016, 8, 6, 10, 26, 9, 669000)
print "%s-%s-%s %s:%s:%s " % (d.year, d.month, d.day, d.hour, d.minute, d.second)
# 2016-8-6 10:38:8
HTTP 协议被设计得非常强大,但很多网络应用都没有利用这些强大之处。比如缓存和HTTP 方法。HTTP为资源的增删改查分别提供了PUT, DELETE, POST, GET等方法,确没有人用。所以,最近兴起的Restful只是对优化web架构、充分利用HTTP协议的能力的一个回归。下面是一些HTTP协议的概述:
1 | # script to register Python 2.0 or later for use with win32all |
https://github.com/cuber/ngx_http_google_filter_module/blob/master/README.zh-CN.md
1 | apt-get install build-essential git gcc g++ make |
nginx 官网:
http://nginx.org/en/download.html1
wget http://nginx.org/download/nginx-1.9.12.tar.gz