CloudFlare Warp is a popular network acceleration tool that helps users speed up and protect their internet connections. To conveniently obtain and manage the Warp Key, I wrote a CloudFlare Warp Key collection tool in Go language, which automatically retrieves the latest CloudFlare WARP KEY every hour. Project address: https://github.com/geeklinux-io/warpkey
You can directly obtain the Warp KEY from the following URL (data updated every hour):
https://raw.githubusercontent.com/geeklinux-io/warpkey/main/data/full
https://raw.githubusercontent.com/geeklinux-io/warpkey/main/data/full
You can also access it through my GitHub Pages:
https://geeklinux-io.github.io/warpkey/
Setting Up the Warp Key Collection Tool
Next, we will detail how to set up this collection tool on your local machine or server.
- Install Go Language
First, please ensure that Go language is installed on your system. If not, you can install it by following these steps:
-
Visit the official Go language website and download the installation package suitable for your operating system.
-
Complete the installation according to the installation guide provided on the official website.
After installation, you can verify if Go is correctly installed by entering the following command in the terminal:
go version
If the version number of Go is displayed successfully, the installation is successful.
- Clone the Project Code
Open the terminal in your local environment and use the following command to clone the project code to your local machine:
git clone https://github.com/geeklinux-io/warpkey.git
cd warpkey
This step will download all the project files to your local environment.
- Configure the Project
In some cases, you may need to modify the project configuration according to your needs. You can achieve this by editing the main.go file. The specific modifications depend on the functionality and goals you want to achieve.
- Run and Build the Project
After configuring the Go environment and making the necessary modifications, you can use the following command to build and run the project:
chmod a+x build.sh
./build.sh
This command will run the build.sh script in the project, automatically placing the built application in the build directory.
Once the build is complete, the tool will collect CloudFlare Warp Keys from Telegram and save them to the /data directory. You can also use a proxy for requests to obtain Warp Keys in specific network environments. You can check the specific usage by running the following command:
./your-built-binary -h
- Automatically Update Warp Key
To ensure timely updates of the Warp Key, you can use the crontab task scheduling feature in Linux to regularly run the update.sh script in the project, submitting the latest Warp Key data to your GitHub repository.
Here is a simple crontab configuration example that updates once an hour:
0 * * * * /path/to/your/update.sh
- Deploy to Server
After successful local testing, you can deploy the application to your server, ensuring that the Warp Key collection tool runs continuously 24 hours a day. The deployment method is similar to local running; you just need to upload the built binary file to the server and set up the crontab task.