@ -10,7 +10,7 @@ shell> cd /etc/nginx/conf.d
# 从代码仓库复制配置文件
shell> cp /var/www/echoIP/conf/nginx/methodA/ip.conf ./
shell> cp /var/www/echoIP/conf/nginx/methodB/ip-sub.func ./
shell> cp /var/www/echoIP/conf/nginx/methodA/ip-sub.func ./
# 修改配置文件,将ip.343.re改为需要部署的域名
shell> vim ip.conf
@ -1,11 +1,13 @@
server {
listen 80;
listen [::]:80;
server_name ip.343.re; # 改为自己的域名
include conf.d/ip-sub.func;
}
listen 443 ssl http2;
listen [::]:443 ssl http2;
ssl_certificate /etc/ssl/certs/343.re/fullchain.pem; # 改为自己的证书
ssl_certificate_key /etc/ssl/certs/343.re/privkey.pem;
@ -1,5 +1,6 @@
location / {
if ($http_user_agent !~* (curl|wget)) {
@ -12,6 +13,7 @@ server {