Git Product home page Git Product logo

cloudflare-proxy-sites's Introduction

Cloudflare Proxy Sites

A powerful and easy-to-use website mirroring tool based on Cloudflare Workers.

Proxy Sites: Vercel Version

https://github.com/seadfeng/vercel-proxy-sites

🌟 Key Features

  • 🆓 Free to use
  • 🌐 Mirror any website with ease
  • 🚀 Quick deployment using Wrangler
  • 🔗 Support for multiple domains
  • 🤖 Automated deployment via GitHub Actions
  • 🛡️ Enhanced privacy and security
  • 🌍 Bypass geographical restrictions
  • ⚡ Improved access spee

Two Types of Proxy Modes

  • Single-Site Reverse Proxy
  • Multi-Site Reverse Proxy

Single-Site

You can use the workers.dev subdomain to access without needing your own domain. When deploying, configure the targetDomain variable.

// workers.dev/index.js
// replace to your target site domain
const targetDomain = 'example.com';

Code: workers.dev/index.js

Multi-Site

You need to have your own domain. The proxy site will be automatically recognized based on the domain name. After deployment, you only need to add custom domains according to the rules. Configure the ownDomain variable when deploying.

// index.js
// replace to your domain
const ownDomain = "example.com";

The domain consists of two parts: target domain and own domain. For example:

Proxy site address: https://www.proxysites.ai.serp.ing

Code: index.js

www.proxysites.ai.serp.ing.png

Local Deploy

1. install wrangler

npm i -g wrangler

2. Configure your own domain - Important!

// index.js
// replace to your domain
const ownDomain = "example.com";

Use workers.dev default domain?

This method only support single domain reverse proxy.

Here is the code:

workers.dev/index.js

// workers.dev/index.js
// replace to your target site domain
const targetDomain = 'example.com';

Get your workers.dev visit:

workers.dev domain

3. deploy to workers

# Login
wrangler login

# Deploy
wrangler deploy

Or Deploy by Workflows

To automate your deployment process, you can use GitHub Actions or a similar CI/CD tool. Below are the steps to set up your deployment workflow and the necessary GitHub secrets:

Configure GitHub Secrets

Add GitHub Secrets

Store sensitive information as secrets in your GitHub repository. Navigate to your repository settings and add the following secrets:

  • CLOUDFLARE_API_TOKEN: Your Cloudflare API token. This token should have permissions to deploy and manage your Cloudflare Workers.
  • CLOUDFLARE_ACCOUNT_ID: Your Cloudflare account ID.

To add secrets:

  • Go to your repository on GitHub.
  • Click on "Settings" in the top menu.
  • Select "Secrets" from the sidebar.
  • Click on "New repository secret" to add each secret.

Manual Cloudflare Setup

For detailed instructions, see this guide

Configure Workers for Proxy Site

eg.

My root domain is serp.ing,

proxy sites www.proxysites.ai, www.serpchecking.com

1. Go Workers & Pages

Make sure you have deployed to Workers

Workers & Pages

2. Add a custom domain for your Worker.

Support multiple domain names, the following only set up a as an example

Add a custom domain

3. Done

Ensure the certificate is active.

Domain config

🤖 robots.txt Configuration

Default configuration (recommended for privacy):

// index.js
const robots = `User-agent: *
Disallow: /
    `;

⚠️ Warning: Modifying this may affect the indexed content of the mirrored site.

📜 Disclaimer

This tool is for educational and personal use only. Users are responsible for complying with all applicable laws and regulations. The developers are not liable for any misuse or legal consequences.

🤝 Contributing

Contributions are welcome! Feel free to submit issues or pull requests.

cloudflare-proxy-sites's People

Contributors

seadfeng avatar

Stargazers

 avatar ivan avatar xyz avatar  niko avatar  avatar  avatar  avatar  avatar  avatar  avatar Tianlu avatar  avatar  avatar 张华粮 avatar zch avatar AndroidEnthusiast avatar  avatar  avatar Abai avatar  avatar  avatar 07 avatar  avatar  avatar 崔健壮 avatar Ma2049 avatar  avatar  avatar Fred avatar zxh avatar Keigo avatar  avatar  avatar  avatar Jiajun Yan avatar Harper avatar KingChen avatar Zheng404 avatar  avatar 刘志聪 avatar DchG avatar  avatar 風で旅士 avatar  avatar Adrian Morgenthal avatar  avatar Aditya Shetty avatar  avatar Andy Don avatar Jiang Wenjian avatar Ravindu Shanaka avatar BetoZeroTres avatar  avatar  avatar  avatar Gustavo de León avatar funjoke avatar Aleksey Ushakov avatar Christian avatar Wildan Zulfikar avatar  avatar Simon Hawkins avatar René avatar  avatar SuriCloud avatar  avatar miao_miao avatar  avatar SK Mezanul Haque avatar  avatar  avatar Wamy avatar Flyher D avatar dragon avatar Jaya avatar  avatar  avatar  avatar HuiWing avatar Ding avatar  avatar  avatar Egor Eremeev avatar YuanXin Hu avatar ProjectNinjaTech avatar  avatar  avatar  avatar Mehmet Akif VESKE avatar  avatar Cusox. avatar Gavin9 avatar 木子欢儿~ avatar  avatar  avatar C04M3 avatar CrankZ avatar liu.qian avatar quysil avatar 季帅 avatar

Watchers

jack avatar  avatar

cloudflare-proxy-sites's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.