Key points for creating Rails Applications in China (in windows 7, Rails 4.2.0) and rails4.2.0

Source: Internet
Author: User

Key points for creating Rails Applications in China (in windows 7, Rails 4.2.0) and rails4.2.0

 

1. the application created using the rails new command will not succeed when the bundle install is automatically executed. Based on the error prompt, it is determined that the cause may be the security problem of the wall and https certificate. as a development environment, you can create a gemrc file in the directory C: \ ProgramData with only one line of code in it:

: Ssl_verify_mode: 0

2. Run the command gem sources-a http://gems.ruby-china.org to add the ruby-china gem source to the system source.

3. run the gem sources command to display the list of configured System sources, and then delete other invalid gem sources, such as "gem sources-r https://rubygems.org/", in sequence using the gem sources-r URL /"

4. run the command bundle install -- retry 10 in the directory of the rails application to install and update gems. the reason for setting retry times is that the gem service cloud storage server where ruby-china is located is not stable currently. You need to execute bundle install repeatedly to install it successfully.

 

For the solution, refer to the website information in the error prompt, which is not listed here.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.