cloudflare/cloudflared ? reverse-engineered prompt

Reverse engineered prompt

Build me a command line tool called cloudflared that lets me set up a secure tunnel from Cloudflare back to my private server.

I want it to act like a small daemon I can run on a machine behind a firewall, so traffic coming in through Cloudflare gets forwarded to my local web app or other origin without me opening inbound ports. It should support the basic tunnel workflow, authentication, routing traffic to an origin, and also private access for things like SSH or other TCP connections.

Make it feel like a real production tool, with clear help commands, good logging, config handling, and support for running as a long lived process. If there are setup details or current Cloudflare docs that would help, look them up online and use the right approach. I also want it to be easy to build from source and test locally.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab