Skip to content

feat(relay): auto-detect China and apply deploy mirrors#1748

Merged
bobleer merged 2 commits into
GCWing:mainfrom
bobleer:feat/relay-deploy-cn-mirrors
Jul 25, 2026
Merged

feat(relay): auto-detect China and apply deploy mirrors#1748
bobleer merged 2 commits into
GCWing:mainfrom
bobleer:feat/relay-deploy-cn-mirrors

Conversation

@bobleer

@bobleer bobleer commented Jul 24, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Auto-detect mainland China at relay one-click / deploy.sh start (IP / timezone / connectivity), with BITFUN_MIRROR=cn|global override
  • Apply host + build mirrors for apt, Docker Hub registry-mirrors, Cargo/rsproxy, GitHub (ghfast), and Docker Engine install (Aliyun docker-ce, jsDelivr fallback)
  • Desktop SSH orchestration embeds the same mirror.sh before Docker install and GitHub sync; Dockerfile accepts BITFUN_USE_CN_MIRROR build-args

Validation (Beijing CN network)

  • HTTP: Aliyun apt, rsproxy crate download, ghfast GitHub raw/git/tarball, jsDelivr docker-install — OK
  • Registry digests: docker.1ms.run, dockerproxy.net, docker.m.daocloud.io for hello-world / debian:bookworm-slim / rust:1.96-bookworm — OK
  • docker pull via configured registry-mirrors for those three images — OK (final clean round: ROUND_FAIL=0 ROUND_SLOW=0)
  • Unit: cargo test -p bitfun-services-integrations --features remote-ssh-concrete --lib mirror

Test plan

  • On a mainland China VPS: Desktop one-click deploy and confirm logs show Mirror mode: cn and faster pulls
  • BITFUN_MIRROR=global bash deploy.sh keeps upstream sources
  • Redeploy on an overseas host remains unchanged by default

bobleer added 2 commits July 25, 2026 00:22
Detect mainland China during one-click / deploy.sh and configure apt,
Docker Hub, Cargo, GitHub, and Docker Engine install mirrors so domestic
servers are not blocked on overseas downloads. Defaults were validated
from a Beijing network path.
@bobleer
bobleer merged commit 1a3d4dc into GCWing:main Jul 25, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant