博主

昨天 19:30在线

拂晓不辍
寒冰之镜前,铁蒺与芳华无声绽放。《加油大魔王》
歌曲封面 未知作品

萌ICP备20259933号

网站已运行 53 天 18 小时 9 分

Powered by Typecho & Sunny

2 online · 66 ms

拂晓不辍 战争没有胜利者,只有失败者。《洛洛历险记》
Title

闲暇时刻写一下这几天的经历

拂晓不辍

·

Article
  1. 将eggk.net进行了备案,并打算将作为博客的永久网址
  2. 给博客设置了一下伪静态
♾️ html 代码:
    if (-f $request_filename/index.html){
    rewrite (.*) $1/index.html break;
    }
if (-f $request_filename/index.php){
    rewrite (.*) $1/index.php;
    }
if (!-e $request_filename){
    rewrite (.*) /index.php;
    }
  1. 决定了博客家改名为三年之约并将网址永久改为nblog.net的决策,但是这个决策好像搞得很多人都厌恶了,都不再相信....时间会说明这一切的吧
  2. 夜晚发现三年之约会跳转违规站点,怀疑是DNS被劫持,立马联系腾讯云那边进行处理,但是对方说我DNS是正常的,我将所有解析进行删除仍在跳转违规站点,这可太可怕了,后等删除解析生效完成之后,已经不再跳转,之后服务器开始不断被攻击,我的博客也被黑洞一天。
  3. 将所有站点加了CDN,再也不裸奔了。并对三年之约服务器加了IP且续费
  4. 对三年之约的conf文件重新进行了分析,并完整适配CDN
♾️ html 代码:
    server {
    listen 80;
    server_name nblog.net;
    # Gzip 设置
    gzip on;
    gzip_min_length 100;
    gzip_comp_level 6;
    gzip_types text/plain application/javascript application/x-javascript text/css application/xml image/jpeg image/gif image/png;
    gzip_static on;
    gzip_vary on;
    gzip_buffers 32 4k;
    gzip_http_version 1.1;

    # URL 重写,确保所有非 www 请求重定向到 www
    if ($host != 'nblog.net') {
        return 301 https://nblog.net$request_uri;
    }

    location / {
        root /usr/share/nginx/dist;
        add_header Cache-Control no-store always;
        try_files $uri /index.html;
    }

    location ~ ^/(api|gravatar|feed\.xml) {
        proxy_pass http://localhost:8080;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    }

    location /websocket {
        proxy_pass http://localhost:8080/websocket;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "Upgrade";
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;
        proxy_set_header Origin "";
        proxy_read_timeout 86400s;
        proxy_send_timeout 60s;
        proxy_connect_timeout 60s;
    }
    
    # 加载默认配置
    include /etc/nginx/default.d/*.conf;
}
nblog.webp
nblog2.webp
  1. 拂晓不辍换主题咯,换成了Sunny主题,并附上了很多功能
现在已有 39 次阅读,0 条评论,0 人点赞
Comment:共0条
发表
搜 索 消 息 足 迹
你还不曾留言过..
你还不曾留下足迹..
博主 网站设置有【CDN】缓存,留言评论或部分独立页面需要12小时才能更新显示! 不再显示
博主