bazel-contrib / SIG-rules-authors

Governance and admin for the rules authors Special Interest Group
https://bazel-contrib.github.io/SIG-rules-authors/
Apache License 2.0
30 stars 12 forks source link

Style guide: document how rules artifacts are mirrored #12

Closed alexeagle closed 1 year ago

alexeagle commented 3 years ago

It happens on many releases of many rulesets, where the mirror.bazel.build GCS bucket doesn't contain the artifact. e.g. https://github.com/bazelbuild/rules_python/issues/566

@meteorcloudy my understanding is that the bazel-central-registry might provide an automation for mirroring releases, is that true?

keith commented 3 years ago

Just a note: at Lyft we have found the mirror.bazel.build mirrors to actually be quite flaky, so we override some dependency URLs just to remove them in place of github whenever possible. I am skeptical we could do much better than github in this case

alexeagle commented 3 years ago

Agreed, and rulesets are just one of many from-the-internet dependencies that bazel may fetch. I think any serious user would want a read-through cache like artifactory and configure Bazel downloader to exclusively pull through there, to avoid dependency on liveness of internet hosts.

meteorcloudy commented 3 years ago

@meteorcloudy my understanding is that the bazel-central-registry might provide an automation for mirroring releases, is that true?

Yes, that's right! And we can easily change mirror source at https://github.com/bazelbuild/bazel-central-registry/blob/main/bazel_registry.json#L2. I'm open to suggestion what CDN we should use, the current one is hosted via GCS, so might not be accessible by users in China 😂.

alexeagle commented 3 years ago

That's great, thanks @meteorcloudy - I think the SIG only needs to update the rules style guide to reflect what a rules author ought to do.

alexeagle commented 1 year ago

I think we can close this as bzlmod will mirror release artifacts to a GCS bucket with no effort required from rules authors.