基于Nginx扩展模块
https://github.com/cuber/ngx_http_google_filter_module/blob/master/README.zh-CN.md
0x01 安装 gcc & git
1 | apt- install build-essential git gcc g++ make |
0x02 下载最新版源码
nginx 官网:
http://nginx.org/en/download.html1
wget http://nginx.org/download/nginx-1.9.12.tar.gz
0x03 下载最新版 pcre
pcre 官网:
http://www.pcre.org/1
wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.37.tar.gz
0x04 下载最新版 openssl
opessl 官网:
https://www.openssl.org/1
wget https://www.openssl.org/source/openssl-1.0.1j.tar.gz
0x05下载最新版 zlib
zlib 官网:
http://www.zlib.net/1
wget http://zlib.net/zlib-1.2.8.tar.gz
0x06 下载google扩展
1 | git clone https://github.com/cuber/ngx_http_google_filter_module |
0x07 下载 substitutions 扩展
1 | git clone https://github.com/yaoweibin/ngx_http_substitutions_filter_module |
0x08 解压缩
1 | tar xzvf nginx-1.9.12.tar.gz |
0x09 编译与安装
1 | # 进入 nginx 源码目录 |
0x10 其中http的配置方式
1 | server { |