|
| 1 | +# Auto Update Download Acceleration |
| 2 | + |
| 3 | +## Problem |
| 4 | + |
| 5 | +OpenLess used a single Tauri updater endpoint on GitHub Releases: |
| 6 | + |
| 7 | +```text |
| 8 | +https://github.com/appergb/openless/releases/latest/download/latest-{{target}}-{{arch}}.json |
| 9 | +``` |
| 10 | + |
| 11 | +The manifest also pointed installer downloads back to GitHub Releases. On networks where GitHub release assets are slow, a small updater package can take minutes to download. |
| 12 | + |
| 13 | +Desktop apps do not reliably inherit a user's shell proxy environment. Instead of making updater correctness depend on whether a proxy is visible to the app process, the updater should use a GitHub release acceleration URL directly. |
| 14 | + |
| 15 | +## Runtime Behavior |
| 16 | + |
| 17 | +The app does not manually probe local proxy ports. It lets the OS/process network stack do whatever it normally does, while the updater endpoint itself points at `fastgit.cc` first. This keeps the rule simple: proxy or no proxy, updater traffic should prefer the fastgit transport. |
| 18 | + |
| 19 | +## Fastgit Acceleration |
| 20 | + |
| 21 | +Release builds now publish two updater manifests per target: |
| 22 | + |
| 23 | +```text |
| 24 | +latest-<target>-<arch>.json |
| 25 | +latest-<target>-<arch>-mirror.json |
| 26 | +``` |
| 27 | + |
| 28 | +The client checks the mirror manifest first, then GitHub. The mirror manifest points its installer URL at: |
| 29 | + |
| 30 | +```text |
| 31 | +https://fastgit.cc/https://github.com/<repo>/releases/latest/download/<asset> |
| 32 | +``` |
| 33 | + |
| 34 | +The updater signature still protects the downloaded package. The mirror only changes transport; it cannot replace the signed payload without verification failing. |
| 35 | + |
| 36 | +## Maintainer Notes |
| 37 | + |
| 38 | +Set `OPENLESS_UPDATE_MIRROR_BASE_URL` in CI to change the mirror host. Keep it formatted as a prefix for GitHub URLs, for example: |
| 39 | + |
| 40 | +```text |
| 41 | +https://fastgit.cc/https://github.com |
| 42 | +``` |
| 43 | + |
| 44 | +If a mirror becomes unreliable, replace that environment value and the mirror endpoint in `openless-all/app/src-tauri/tauri.conf.json`. |
| 45 | + |
| 46 | +## Evidence |
| 47 | + |
| 48 | +Measured from Windows on 2026-05-01. Direct GitHub release downloads were tested with local proxy disabled to reproduce the slow path. `fastgit.cc` was tested both through the normal local proxy environment and with local proxy disabled; results vary by route, so do not treat one machine's no-proxy number as a CDN SLA. |
| 49 | + |
| 50 | +```text |
| 51 | +Direct GitHub installer asset, 4.78 MB, proxy disabled: |
| 52 | +run 1: timed out after 90.75s, 1.73 MB received |
| 53 | +run 2: timed out after 90.06s, 2.44 MB received |
| 54 | +
|
| 55 | +fastgit.cc installer asset, 4.78 MB, normal local proxy environment: |
| 56 | +with protocol prefix: 3.12s / 3.63s / 3.39s |
| 57 | +without protocol prefix: 2.92s / 2.45s / 2.87s |
| 58 | +
|
| 59 | +fastgit.cc target-user signal: |
| 60 | +manual browser/download usage reported completing in under 1s without enabling a proxy. |
| 61 | +``` |
| 62 | + |
| 63 | +This is enough to justify a `fastgit.cc` mirror path, but not enough to treat a public mirror as permanently trusted infrastructure. `fastgit.cc` explicitly documents support for GitHub release/archive acceleration and accepts GitHub links with or without the protocol prefix. Keep the mirror configurable and re-test before each release if download performance is a release blocker. |
0 commit comments