Here says I can change mirror by setting RUBY_BUILD_MIRROR_URL
environment variable:
You can point ruby-build to another mirror by specifying the RUBY_BUILD_MIRROR_URL environment variable--useful if you'd like to run your own local mirror, for example. Package mirror URLs are constructed by joining this variable with the SHA2 checksum of the package file.
Then I set it. But it doesn't work:
aries@mac-book-air: echo $RUBY_BUILD_MIRROR_URL
https://ruby.taobao.org
aries@mac-book-air: rbenv install 2.3.0
Downloading ruby-2.3.0.tar.bz2...
-> https://cache.ruby-lang.org/pub/ruby/2.3/ruby-2.3.0.tar.bz2
Besides, I didn't set RUBY_BUILD_SKIP_MIRROR
variable in my env.
rbenv version: 1.0.0, ruby-build is the latest version. Mac OS X version:
ProductName: Mac OS X
ProductVersion: 10.11.4
BuildVersion: 15E65
We can see that it does not use the mirror I set with that environment variable.
Anyone knows how to solve that? Thank you.
according to this I find that the mirror url does not support it. problem solved.