Skip to content
This repository was archived by the owner on Mar 15, 2026. It is now read-only.

Add community mirror#532

Merged
mlugg merged 1 commit into
ziglang:mainfrom
inge4pres:main
Mar 12, 2026
Merged

Add community mirror#532
mlugg merged 1 commit into
ziglang:mainfrom
inge4pres:main

Conversation

@inge4pres

Copy link
Copy Markdown
Contributor

The mirror is geographically redundant and fast thanks to Cloudflare CDN.
Instructions to replicate the same setup are also added in MIRRORS.md.

@alexrp alexrp requested a review from mlugg September 23, 2025 23:21

@linusg linusg left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The "How to use" and "Why choose zigmirror.com?" sections on the marketing website are not in spirit of the Zig community mirror list IMO. Statements like "The fastest community mirror to download Zig binaries" ought to be backed up with numbers.

@inge4pres

inge4pres commented Oct 6, 2025

Copy link
Copy Markdown
Contributor Author

Hey @linusg 👋🏼 thanks for the hint, the website is simply a display page that show the property of the mirror - it's not meant much for marketing but for displaying how it's done, and why.

I actually re-run the numbers since the PR was implemented and noticed that other mirrors have a similar download bandwidth and latency (they can download a cached tarball in ~2 second, and uncached in ~12 secs).
As for availability, it falls back to the Cloudflare SLAs for web and R2, as there are no other components involved, it's a completely managed service.

Let me know if I should update the website, which is not in this repo, for the PR to be accepted.
The failing check in CI does not seem related to the mirror implementation, which I had tested with the check-mirror script.

Here's what I used now just now to check the latency (for cached tarballs)

☁  www.ziglang.org [main] ⚡  curl -iLO https://zigmirror.com/zig-0.14.1.tar.xz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 16.9M  100 16.9M    0     0  6589k      0  0:00:02  0:00:02 --:--:-- 9080k
☁  www.ziglang.org [main] ⚡  curl -iLO https://pkg.machengine.org/zig/zig-0.14.1.tar.xz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16.9M  100 16.9M    0     0  2309k      0  0:00:07  0:00:07 --:--:-- 2071k
☁  www.ziglang.org [main] ⚡  curl -iLO https://zigmirror.hryx.net/zig/zig-0.14.1.tar.xz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16.9M  100 16.9M    0     0  2284k      0  0:00:07  0:00:07 --:--:-- 3604k
☁  www.ziglang.org [main] ⚡  curl -iLO https://zig.florent.dev/zig-0.14.1.tar.xz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16.9M  100 16.9M    0     0  4004k      0  0:00:04  0:00:04 --:--:-- 4004k
☁  www.ziglang.org [main] ⚡  curl -iLO https://zig.mirror.mschae23.de/zig/zig-0.14.1.tar.xz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16.9M  100 16.9M    0     0  8931k      0  0:00:01  0:00:01 --:--:-- 8931k
☁  www.ziglang.org [main] ⚡  curl -iLO https://zigmirror.meox.dev/zig-0.14.1.tar.xz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16.9M    0 16.9M    0     0  7551k      0 --:--:--  0:00:02 --:--:-- 7552k

@mlugg

mlugg commented Nov 6, 2025

Copy link
Copy Markdown
Member

Sorry it's taken me so long to look at this.

Yes, I'd like to ask for the front page to be modified. Like @linusg, I'm not a fan of how the content of that page pits this community mirror against others; the whole point of the community mirror project is to cooperate to improve everyone's experience by distributing the task of serving tarballs and eliminating SPOFs. Regardless of the numbers, I would like to request that:

  • The line "The fastest community mirror to download Zig binaries" be removed. (The mention of "fastest" is the problem; a less boastful subtitle is of course fine.)
  • The "How to use" section be either removed, or replaced with instructions for using the general community mirrors system (i.e. probably just a link to Community Mirrors). The whole point of this system is that people shouldn't hardcode to a single mirror.
  • The "Why choose zigmirror.com" section be either removed, or renamed to something less competitive-seeming (e.g. "Features", "Performance", "About this mirror", or similar).

Personally, I would prefer if the landing page were entirely replaced, either with a simple page containing details about this mirror, or even just with a redirect to Community Mirrors. However, I'd be okay with merging given the changes listed above; I just don't want any mirror to paint itself as superior to others and thereby encourage fragmentation within the ecosystem of mirrors. Thank you!

@inge4pres

inge4pres commented Nov 15, 2025

Copy link
Copy Markdown
Contributor Author

@mlugg @linusg thanks both for the insightful review 🙏🏼
I appreciate the honesty and please accept my apologies for trying to show off my solution to hosting a mirror.

I've addressed the conflicts an the landing page is modified as the following.
image

Can you confirm the CI failure is not related with how the new mirror works?
I tested it before raising the PR and all looked good.

Secondarily: WDYT of the addition to MIRRORS.md?

@inge4pres inge4pres requested a review from linusg March 5, 2026 11:00
@mlugg mlugg force-pushed the main branch 2 times, most recently from a66a8bf to ca8bf3f Compare March 12, 2026 13:37
@mlugg

mlugg commented Mar 12, 2026

Copy link
Copy Markdown
Member

(Sorry review has taken so long. I'm currently working on fixing up the "Check Mirrors" action; I'll hopefully be able to merge this, or let you know of any issues, by the end of today!)

Signed-off-by: inge4pres <fgualazzi@gmail.com>
@mlugg

mlugg commented Mar 12, 2026

Copy link
Copy Markdown
Member

Disregard the CI failure, it's not your mirror that's failing. This looks good now, and the new landing page is fine. Thank you for helping to improve the Zig ecosystem!

@mlugg mlugg merged commit f440953 into ziglang:main Mar 12, 2026
2 of 3 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants