Pixiv - KiraraShss
72 字
1 分钟
nginx直接返回ip
## nginx配置
location / { add_header Content-Type "text/plain; charset=utf-8"; # 直接返回客户端IP access_log off; # 使用 echo 模块(如果安装了) echo $remote_addr;
}然后浏览器或者py、go都可以直接请求返回ip 示例代码:curl ip.bgspider.com
使用cdn+nginx
location / { return 200 "$http_x_forwarded_for"; add_header Content-Type text/plain; } 最后更新于 2025-12-09,距今已过 1 天
部分内容可能已过时