cloudflare-load-balance-manager is an easy to use CLI tool that lets you easily register and deregister instances with a Cloudflare load balancer. This is useful during deployments to stop traffic to your instance then resuming traffic after your deployment is complete.
npm install -g cloudflare-load-balance-manager
cloudflare-load-balance-manager <command> <options>
Commands:
register
(Register instance to Cloudflare)deregister
(Deregister instance to Cloudflare)
Example command:
cloudflare-load-balance-manager register --email [email protected] --api-key abcdefghijlmnopqrstuvwxyzabcde --name lb1
cloudflare-load-balance-manager deregister --email [email protected] --api-key abcdefghijlmnopqrstuvwxyzabcde --name lb2
Help command:
cloudflare-load-balance-manager --help
cloudflare-load-balance-manager -h