vim /etc/apt/sources.list
deb http://nginx.org/packages/mainline/debian wheezy nginx
deb-src http://nginx.org/packages/mainline/debian wheezy nginx
#wheezy是你自己的debian版本
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com ABF5BD827BD9BF62
apt-get update -y
apt-get upgrade -y

按上述指令执行后即可通过apt-get install -y nginx安装包含http2模块的nginx服务了。当然,其实自己编译也是OK的。

Related Posts: Debian-apt-get安装包含http2的Nginx服务 :