Website Optimization (1): Network and Region — BGP
In this year's update, the very first thing I considered was where to deploy the program, which data center to pick, and which network to use. So part one shares my reasoning and experience.
27 posts
In this year's update, the very first thing I considered was where to deploy the program, which data center to pick, and which network to use. So part one shares my reasoning and experience.

This "ip.renfei.net" upgrade supports not only IPv4 networks but also IPv6 networks, so the JSON you get may be an IPv4 or an IPv6 address. Developers, please update your programs to recognize it. If you only want to query an IPv4 address, use "ipv4.renfei.net", which supports IPv4 only.

ip.renfei.net pairs with DDNS dynamic DNS resolution for resolving dynamic IPs. In a dynamic-IP environment, it conveniently updates domain resolution records in time. On Linux, use curl ip.renfei.net to quickly query the public outbound IP. In a browser, use JavaScript to request ip.renfei.net to get the user's public IP address.

Not long ago my site connected to the WeChat Official Account platform. Debugging was inconvenient — deploy the code to the server to test? That's unlikely, and could even affect the live system. So I used the intranet penetration service provided by ngrok to map my computer to the internet. Today I'll share how to use ngrok for intranet penetration and map your computer to the internet.

Charles is a web proxy (HTTP proxy / HTTP monitor) that runs on your own computer. Then, configure your web browser (or any other Internet application) to access the Internet through Charles, and Charles can record and display all the data you send and receive.

You can't directly see the public IP on a computer or server—only the internal IP is visible—so a program cannot know the address of its Internet exit. I wrote another app to obtain the public IP address. It is implemented using serverless function compute, with good availability and speed, so I'm sharing it for everyone to use.

When renovating a home we pre-bury Ethernet cables, and we also buy some in daily life, but the market is a mess — Cat5e, Cat6, Cat6a, Cat7, even Cat8 and Cat9. How not to get ripped off by shady sellers? Today I'll explain how to choose Ethernet cables.



