-
2019.01
27
nginx -t nginx: [emerg] unknown directive " " in /etc/nginx/conf.d/gw_waf.conf:2 nginx: configuration file /etc/nginx/nginx.conf test failed
var cnzz_protocol = (("https:" == document.location.protocol) ? " https://" : " http://");document.write(unescape("%3Cspan id='cnzz_st...
-
2018.11
28
nginx –t
报错 nginx: [emerg] module "/usr/lib64/nginx/modules/ngx_http_geoip_module.so" version 1012002 instead of 1014001 in /usr/share/nginx/modules/mod-http-geoip.conf:1
解决方案 1
卸载 再安装
yum remove nginx yum update nginx yum install -y nginx s...
-
2018.11
28
Setup HTTPS on Nginx
Optimize HTTPS on Nginx and get an A+ score on the SSLlabs test.
Optionally, set up HTTP Public Key Pinning (HPKP)
Redirect all HTTP traffic to HTTPS in your Nginx config:
默认服务器写法
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name _;
r...
-
2018.11
28
Pre-Built Packages for Stable version
To set up the yum repository for RHEL/CentOS, create the file named /etc/yum.repos.d/nginx.repo with the following contents:
[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/OS/OSRELEASE/$basearch/
gpgcheck=0
Replace “OS” with “rhel” or “centos”, de...
-
2018.10
30
访问网站的任何页面,都跳转到同一个页面
server { listen 80; index index.html index.htm;
server_name www.example.com;
if ($request_uri !~ "^/502.html$") { rewrite ...
-
2018.10
19
server { listen 80; server_name 域名;
access_log /prdacc1.log ; error_log /prderr1.log; location / { proxy_set_header X-Real-IP $remote_a...
-
2018.10
15
将真实IP $remote_addr赋值给 X-Forwarded-For即可。
proxy_set_header X-Forwarded-For $remote_addr; # proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
-
2018.07
31
如果我们在 nginx 下搭建了一些站点,但是由于站点内容或者流量的关系,我们并不想让所有人都能正常访问,那么我们可以设置访问认证。只有让用户输入正确的用户名和密码才能正常访问。效果如下:
nginx 开启访问验证
在 nginx 下,提供了 ngx_http_auth_basic_module 模块实现让用户只有输入正确的用户名密码才允...
-
2018.07
21
说明: 已经安装好的nginx,需要添加一个未被编译安装的模块,需要怎么弄呢?
具体: 这里以安装第三方ngx_http_google_filter_module模块为例 nginx的模块是需要重新编译nginx,而不是像apache一样配置文件引用.so 1. 下载第三方扩展模块ngx_http_google_filter_module
# cd /data/software/
# git ...
-
2018.07
19
nginx 反向代理到其它https网站是不可能的,当然同域名是可以的 nginx 反赂代理到https后端是可以的
查看nginx 是否有ssl模块
nginx -v
–with-http_ssl_module
到免费网站上申请ssl证书 https://freessl.org/
并下载
下载的文件有两个:
1,ss.pem
2,ss.key
五,服务器安装,配置nginx
登录到服务...
有实验图就更好了
厉害啊
hhh
说的很有道理!
楼主好人啊,我现在就是小时候的你
...
APK从哪来?不是免费的把?
每天睡觉以前,我都会把您的帖子再
漂亮,好方法,
楼主,请原谅我的自私!我知道无论