Use a fallback mirror for code.dlang.org#273
Conversation
|
Thanks for your pull request, @wilzbach! Bugzilla referencesYour PR doesn't reference any Bugzilla issue. If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog. |
script/install.sh
Outdated
| logV "Determining latest dub version ($url)." | ||
| version=$(fetch $url) | ||
| if [ -z "${version}" ] ; then | ||
| version=$(curl -s https://api.github.com/repos/dlang/dub/releases/latest | grep tag_name | sed -e 's/.*"tag_name": "v\([^"]*\)".*/\1/') |
There was a problem hiding this comment.
This will be replaced soon once an actual mirror for LATEST exists
|
Are you okay with adding this fallback mirror @MartinNowak? |
|
What's wrong with this? Code.dlang.org is often down and we mirrored all dub releases to GitHub. |
code.dlang.org is often down and there's no mirror for http://code.dlang.org/download/LATEST yet See also: - dlang/dub#1290 - dlang/installer#273 - dlang/installer#291 CC @ibuclaw
|
A few things have changed here:
-> I'm reopening this, s.t. it doesn't get forgotten and I will revive and rebase it once #291 has been merged. |
Done. Also note that the DUB binaries will soon be auto-deployed to GitHub, s.t. code.dlang.org/download might be retired. |
|
Going to merge this now as the errors are still a thing, I'm tired of waiting for such a simple fix and the backup "mirror" now got the primary "upstream" for the binaries. |
| dub="dub-$(fetch $url)" | ||
| local latestMirrors=( | ||
| "http://code.dlang.org/download/LATEST" | ||
| "http://dlang.github.io/dub/LATEST" |
There was a problem hiding this comment.
I think simply because it wasn't using https before
|
Sorry, must have forgotten to submit a comment or accidentally hit the close button. Definitely helpful in the short-term. It's still a bit unfortunate that dub releases are lingering between dlang.org and code.dlang.org (and now GH). How about just archiving old dub releases that preceed the dmd integration. My main point here is to avoid the maintenance overhead of a second release pipeline when we already have established infrastructure and processes in place. |
As #218 doesn't seem to be moving forward, I have uploaded all DUB releases to GitHub, which should be much more reliable (see dlang/dub#1290 for details).
At the moment, there isn't a mirror for
code.dlang.org/download/LATEST(we should probably create a gh-pages repo like LDC or use an S3 bucket), so for now I simply used the GitHub API. I know that it's rate-limited, but imho having a chance to succeed is a lot better than having none.If code.dlang.org is down, we still manage to get the latest DUB: