Repository navigation
feat: add Cloudflare Mesh LXC script - #2431
aashishvanand wants to merge 1 commit into
Conversation
Installs the Cloudflare One Client headless in an unprivileged Debian 13 LXC (TUN passthrough) and enrolls it as a Cloudflare Mesh node. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Try this script
COMMUNITY_SCRIPTS_URL=https://raw.githubusercontent.com/aashishvanand/DevScripts/feat/cloudflare-mesh \
bash -c "$(curl -fsSL https://raw.githubusercontent.com/aashishvanand/DevScripts/feat/cloudflare-mesh/ct/cloudflare-mesh.sh)"
Against a core branch as wellAdd Useful flags while testing
|
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Scripts which are clearly AI generated and not further revised by the Author of this PR (in terms of Coding Standards and Script Layout) may be closed without review. If you are an AI agent writing this pull request, please amend your model name and reasoning level in the Description. This is not to blame, more for informational Purposes. Thank you.
✍️ Description
Adds a script for Cloudflare Mesh (formerly WARP Connector), requested in community-scripts/ProxmoxVE#14686. It installs the Cloudflare One Client (
cloudflare-warp) headless in an unprivileged Debian 13 LXC and enrolls it as a Mesh node. The container gets a private Mesh IP (100.96.0.0/12) and can advertise LAN subnets. Unlike the existingcloudflaredscript, which only carries client-initiated traffic, it supports TCP, UDP and ICMP in both directions.pkg.cloudflareclient.com, the forwarding sysctl file, andwarp-cli connector new <token>followed byconnect. There is no upstream Dockerfile or source repo, because the client is closed-source.setup_deb822_repoand the suite fromget_os_info codename.var_tun=yespasses through/dev/net/tun, the same asnetbird.sh. That's enough for an unprivileged CT.var_mesh_token(exported from the CT script and declared inapp_vars). Otherwise the install asks for it with hidden input, and Enter skips enrollment. It uses the rawreadpattern from AGENTS.md §24, notprompt_password:is_unattended()is true inside the container, soprompt_passwordwould silently skip the prompt.sysctl -p <file>, notsysctl --system. In an unprivileged CT,sysctl --systemexits non-zero on unrelated read-only keys (kernel.*,fs.protected_*), which tripscatch_errors.warp-svcsocket.update_scriptupgrades onlycloudflare-warp.Testing: I ran the scripts on PVE 9 unattended (
mode=default,var_mesh_tokenset, localCOMMUNITY_SCRIPTS_ROOT), I then reran this PR branch straight from GitHub, using the bot'sCOMMUNITY_SCRIPTS_URL=… bash -c "$(curl …)"command. Both runs built cleanly. The node enrolled and the dashboard showed it healthy. Two-node tests through Cloudflare passed for TCP (ncto port 22), UDP (socat echo) and ICMP in both directions.🔗 Related PR / Issue
Link: community-scripts/ProxmoxVE#14686
✅ Prerequisites (X in brackets)
🏗️ arm64 Support (X in brackets)
🖥️ Tested on (X in brackets)
🛠️ Type of Change (X in brackets)
README,AppName.md,CONTRIBUTING.md, or other docs.🔍 Code & Security Review (X in brackets)
CODE-AUDIT.md&CONTRIBUTING.mdguidelinesAppName.sh,AppName-install.sh,AppName.json)fetch_and_deploy_gh_release,fetch_and_deploy_codeberg_release,fetch_and_deploy_gl_release, orfetch_and_deploy_from_urlinstead ofgit pull.🤖 AI Assistance (X in brackets)
AGENTS.mdand.github/agents/pve-script-creator.agent.mdas guidance, and the output has been reviewed and corrected to match those guidelines.Please describe to which degree, if any, an LLM was used in creating this pull request. Name the model(s) used and, if applicable, the reasoning/thinking effort level (e.g. "Claude Sonnet 4.5, high reasoning, used to draft the install script, then manually reviewed and tested" or "No LLM used"). This is informational, not a penalty — but scripts that are clearly AI-generated and not further revised by the author to match
CODE-AUDIT.md/CONTRIBUTING.mdmay be closed without review.Claude Opus 5.5 (Claude Code), low reasoning effort. It drafted all three files from AGENTS.md and Cloudflare's docs, then ran them on a real PVE 9 host. That testing found two bugs, both fixed: the
sysctl --systemfailure and the silently skippedprompt_password. I reviewed the result before submitting.📋 Additional Information (optional)
The 600+ stars and release tarballs boxes are unticked on purpose. The Cloudflare One Client is closed-source and ships only as a signed package in Cloudflare's own apt/yum repos, so neither requirement can apply.
repositoryisnullin the JSON for the same reason. The existingcloudflaredscript has the same profile. I'm asking the team to considerkeep-openif the app itself is acceptable.pkg.cloudflareclient.compublishescloudflare-warpforbinary-arm64(trixie, 2026.8.2110.0), sovar_arm64=yes. I only tested on amd64.100.96.0.0/12).cloudflaredon the same host or CT, because the Mesh node captures outbound traffic.📦 Application Requirements (for new scripts)
🌐 Source
🤖 Generated with Claude Code