liuzhen932/app-cloudflared

By liuzhen932

β€’Updated 8 days ago

Unofficial cloudflared Docker Image

Image
Networking
Developer tools
Web servers
0

636

liuzhen932/app-cloudflared repository overview

⁠🌐 liuzhen932's Unofficial Cloudflared Docker Image 🐳

⚠️ This Docker image is not an official Cloudflare product.

This image supports multiple architectures πŸ’‘, making it compatible with a wide range of devices.

The public image currently supports:

Docker TargetKnown AsNotes
linux/amd64x86_64βœ… Most modern PCs and servers use this architecture.
linux/386x86πŸ’» For older 32-bit Intel/AMD CPUs β€” typically found in legacy systems.
linux/arm64aarch64πŸ’ 64-bit ARM hardware β€” ideal for Raspberry Pi 2/3/4 running 64-bit OS.
linux/s390xIBM ZπŸ–₯️ Designed for IBM mainframes β€” learn more here⁠.
linux/loong64ιΎ™θŠ―πŸ’– ζœͺη»θΏ‡ζ΅‹θ―•οΌŒζ¬’θΏŽει¦ˆ

This image should behave similarly to the official Cloudflared image⁠.


⁠☁️ Cloudflare Tunnel πŸ”‘

Here’s a sample docker-compose.yml file using Zero Trust dashboard setup:

services:
  cloudflared:
    image: liuzhen932/app-cloudflared:latest
    restart: unless-stopped
    command: tunnel run
    environment:
      - TUNNEL_TOKEN=${TUNNEL_TOKEN}

πŸ“’ Note:
Earlier versions of this README suggested using --token ${CLOUDFLARED_TOKEN}, which is less secure ❌.
Using the TUNNEL_TOKEN environment variable is a safer and better approach βœ….

⁠🌐 DNS-over-HTTPS (DoH) Support

While not the primary purpose of this image, you can also deploy it as a DNS resolver that forwards queries to a DNS-over-HTTPS backend πŸ”.

β πŸš€ Example Command
docker run -d -p 53:53/udp --name cf-proxy-dns liuzhen932/app-cloudflared:latest proxy-dns --address 0.0.0.0

This creates a DNS resolver container (cf-proxy-dns) that listens for DNS requests on your host πŸ“‘.

⚠️ Security Note:
On public servers (e.g., VPS), this defaults to listening on all interfaces, exposing your server as a public DNS resolver 🌍.
To restrict it to localhost only (safer):

-p 127.0.0.1:53:53/udp
β πŸ”„ Customize Upstream Servers

Add --upstream to specify alternative DNS backends, e.g.:

--upstream https://dns.example.com

Defaults to Cloudflare DNS (https://cloudflare-dns.com/dns-query) if unspecified βœ….

Tag summary

Content type

Image

Digest

sha256:17cbf0363…

Size

9.7 MB

Last updated

8 days ago

docker pull liuzhen932/app-cloudflared