开个torquebox配置的文章做记录。
官网 : http://torquebox.org/
下载一个最新的,
点击 官方文档的地方: Documentation
我的服务器是centos6.2
检查java版本:java -version
需要在1.6以上,基本现在都是1.6以上的。
yum install httpd-devel openssl-devel zlib-devel gcc gcc-c++ curl-devel expatdevel gettext-devel mysql-devel readline-devel libxml2-devel libxslt-devel
yum install make libtool autoconf automake imake expat-devel
上传torquebox-dist-2.1.2-bin.zip到/root/tool下(我默认的地方,不一定)
解压:
unzip -q torquebox-dist-2.1.2-bin.zip
ln -s torquebox-2.0.3 torquebox-current
在etc/profile修改
export TORQUEBOX_HOME=$HOME/torquebox-current
export JBOSS_HOME=$TORQUEBOX_HOME/jboss
export JRUBY_HOME=$TORQUEBOX_HOME/jruby
export PATH=$JRUBY_HOME/bin:$PATH
使配置生效: source /etc/profile
$ mkdir -p ~/torquebox_examples/rails_example
$cd ~/torquebox_examples/rails_example
A)jruby -S gem install activerecord-jdbc-adapter --no-ri --no-rdoc
B)jruby -S gem install jdbc-mysql activerecord-jdbcmysql-adapter --no-ri --no-rdoc
C)jruby -S gem install jruby-openssl --no-ri --no-rdoc
D)jruby -S gem install rails --no-ri --no-rdoc
jruby -S gem update --system
rails new dms -d mysql
//todo 修改数据库配置
bundle install
rake db:create
在项目根目录下跑: torquebox deploy
jboss下jboss/standalone/configuration配置文件standalone.xml
<interfaces>
<interface name='management'>
<inet-address value='${jboss.bind.address.management:127.0.0.1}'/>
</interface>
<interface name='public'>
<inet-address value='${jboss.bind.address:127.0.0.1}'/>
</interface>
<interface name='unsecure'>
<!-- Used for IIOP sockets in the standarad configuration.
To secure JacORB you need to setup SSL -->
<inet-address value='127.0.0.1'/>
</interface>
</interfaces>
改为
<interfaces>
<interface name="management">
<inet-address value="0.0.0.0"/>
</interface>
<interface name="public">
<inet-address value="0.0.0.0"/>
</interface>
<interface name="unsecure">
<inet-address value="0.0.0.0"/>
</interface>
</interfaces>
./standalone.sh
nohup ./standalone.sh &
重启torquebox ,8080端口可以访问了(如占用了,需要修改端口)。
分享到:
相关推荐
本文介绍了JRuby的安装与配置。JRuby的安装需要JRuby以及JDK,本文使用的版本分别是JRuby 1.1.2以及Java 1.6。至于JRuby配置,文章主要介绍了测试JRuby安装的方法。
JRuby 9.0.0.0 + Torquebox 4 样板 这个样板 Rack 应用程序被设计为高性能 Web 应用程序的起点。 它包含 Torquebox 4 的 Web 组件,目前被认为是Ruby 应用服务器。 选择 JRuby 9.0.0.0 是因为它支持 Ruby 2.2。 ...
Jruby,cucumber,celerity,配置 仅供参考, 注,如果你的机器上有ruby与jruby,请将jruby的环境变量在前,否则配置会失败
See how JRuby fits into the enterprise by switching your app to use TorqueBox, an all-in-one JRuby environment that includes built-in support for messaging, scheduling, and daemons--perfect for ...
jruby安装包 和 jruby的lib库 JRuby是面向Ruby、基于Java虚拟机(JVM)的一种解释程序,它结合了Ruby语言的简易性和功能强大的JVM的执行机制,包括与Java库 全面集成。Rails彻底加快及简化了Web应用的开发,不过它让...
TorqueBox - 一个Ruby应用程序服务器建立在JBoss AS7和JRuby之上
jruby是一个ruby的解析器,可将ruby解析为java文件,jruby作为ruby解析器时刻调用java代码
jruby-complete-1.7.19.jar,java版本的ruby解析器
jruby-1.3.1.jar包 解决org.jruby.exceptions.JumpException 等报错
jruby-src-1.0.zip
org.jruby.rar
jruby-bin-1.3.1.zip 用于jruby语言研发的必要工具
JRuby window X64 开发软件
Now you can bring the best of Ruby into the world of Java, with Using JRuby. Come to the source for the JRuby core team’s insights and insider tips. You’ll learn how to call Java objects seamlessly ...
jruby-dist-9.1.15.0-bin.zip JRuby是面向Ruby、基于Java虚拟机(JVM)的一种解释程序,它结合了Ruby语言的简易性和功能强大的JVM的执行机制,包括与Java库 全面集成。 截至2017.12.08最新稳定版 JRuby 官方更新说明:...
jruby与java使用开发,听说jruby能是swing的调用变为更简单
jRuby On Rails WEB 2.0
对于Jruby、Jython和Groovy三种动态语言,长期以来很多人犹豫于如何选择它们。本文提出一个非常有力的例证证明:如果你是一个基于Java虚拟机的开发者,那么请放弃Jruby和Jython。
JRuby语言实战技术,java下运用ruby
jruby 1.9.6 win64