Windows installation JRuby generate war to Tomcat run

Source: Internet
Author: User

Windows installation JRuby Rails

Download JRuby directly, without Ruby.

Http://jruby.org/download

The installation package can be equipped with environment variable%jruby_home% and so on.

Install bundler (may not need to install, forget)

gem install bundler

Installing rails:

4.2.6
rbenv rehash

Modify Gemfile

Bundle Install

Run

With Ubuntu.

JRuby Rails runs on tomcat-generated war

Installing Warbler

Gem Install Warbler

Installing sprockets

Gem Install sprockets

Pre-compiled assets

Rake Assets:precompile

Generate War:

Bundle Install

Warble.bat Config force=1

Warble

Get a war with the same name as the app, such as Hello.war.

Run in Tomcat

The tomcat launch parameter is added to the environment variable (catalina.sh):

Secret_key_base= 78ec95bf6126680a7b57db21f9db456f2570fd09ac3a6b3fe9dbe5d52f3377c0cff79999ec50c8afb32d2c74afd33e2199fc4f0cbd72ee243a59dcf49 D34e5e4

The secret key can be generated by itself and must have. Build command:

Bundle EXEC Rake Secret

The war can be imported to run.

Windows installation JRuby generate war to Tomcat run

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.