Installing rvm, ruby, bundler and Redmine in China
So, probably you have already heard of "the great firewall of china" is it built to protect us from Chinese hackers? Or built to protect Chinese servers from the rest of the world? I don't know... All I know is that it will give you trouble when you try to install rvm, ruby, bundler and eventually Redmine through it.
This method is using rvm to install custom ruby version under user's account, as explained in Chapter 1 of Redmine Cookbook
One thing I found especially difficult is obtaining rvm, and ruby...
Luckily there is an workaround explained on https://ruby-china.org/wiki/rvm-guide
Which instructs following commands to be entered to install rvm and later ruby
1. Install latest version of RVM
$ gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 $ \curl -sSL https://get.rvm.io | bash -s stable
2. Then add following mirror of Rubies
$ echo "ruby_url=https://cache.ruby-china.org/pub/ruby" > ~/.rvm/user/db
3. Install ruby version that you need
$ rvm install 2.3.3
4. Configure mirror for ruby gems
do the following:
gem sources --add https://gems.ruby-china.org/ --remove https://rubygems.org/ $ gem sources -l https://gems.ruby-china.org # 确保只有 gems.ruby-china.org
5. install bundler
$ gem install bundler
6. Make sure that bundler is using china mirror!
$ bundle config mirror.https://rubygems.org https://gems.ruby-china.org
After all this tasks are done, you can proceed by installing and running Redmine in some of ways as described in the book!
Please don't forget to buy the book, to support my work!