在测试服务器上部署jruby或grails,无需编译
我正在研究使用 jvm 语言进行 Web 开发的可行性。我正在评估 Rails 和 grails 上的 jruby。到目前为止,部署这些的唯一方法似乎是制作一个 war 文件并将其部署到 tomcat 或 glassfish 等应用程序服务器。我只是想将我的源代码放在服务器上,就像我在 Rails 上使用常规 ruby 一样。我了解编译它的好处,并且我不会寻找关于为什么更好的争论。这是一个测试环境,客户能够评估他们的应用程序,并允许我进行快速更改,而无需显式重新编译应用程序。我喜欢使用 scm 在本地进行更改,然后将更改拉到服务器上的能力。是否有任何应用程序服务器具有此功能?如果有,我该怎么做?
I'm investigating the viability of using jvm languages for web development. I'm evaluating jruby on rails and grails. So far it looks like the only way to deploy these is to make a war file and deploy it to an application server like tomcat or glassfish. I just want to throw my source code up on a server like I do with regular ruby on rails. I understand the advantage to having it compiled and I'm not looking for arguments as to why that's better. This is on a testing environment for clients to be able to evaluate their application and to allow me to make quick changes that don't take recompiling the application explicitly. I like the ability to use scm to make changes locally and then pull the changes on the server. Do any of the application servers have this ability and if so how do I do it?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
通常,Grails 开发人员使用 grails run-app 脚本来运行指向其源代码的本地 Tomcat 实例。它没有针对性能进行优化,因此通常以这种方式运行公共服务器是一个坏主意,但如果您可以接受性能权衡,那么您可以这样做。您可以使用“prod”环境使事情变得更快一些,例如,
您甚至可以在服务器上配置 scm 工具以签出源代码并从那里运行,或者如您所说,从本地计算机手动更新文件。
Typically Grails developers use the
grails run-app
script to run a local Tomcat instance pointing at their source code. It's not optimized for performance so it'd be a bad idea in general to run a public server this way, but if you're ok with the performance tradeoffs then you could do that. You can make things a bit faster using the 'prod' environment, e.g.You could even configure your scm tool on the server to checkout the source code and run from there, or as you said manually update the files from your local machine.