简体   繁体   English

我可以直接在我的公司网站上部署Rails应用程序吗?

[英]Can I deploy a Rails App directly onto my companies website?

I have originally been hosting my apps on Heroku, however this is not an acceptable deployment method in my current environment. 我最初在Heroku上托管我的应用程序,但是在我当前的环境中这不是一种可接受的部署方法。 We have personal information in our applications that deploying to Heroku and setting up DNS forwarding is not acceptable. 我们在部署到Heroku的应用程序中有个人信息,并且不接受设置DNS转发。 Regardless of how 'secure' or 'reliable' anyone may think it is, it is just not acceptable in my case. 无论任何人都认为它是“安全的”或“可靠的”,在我的情况下这是不可接受的。

Our host is siteturn.com, integrated with Plesk 10.4.4. 我们的主机是siteturn.com,与Plesk 10.4.4集成。 If I SSH onto our websites server as admin and type 如果我以管理员身份登录我们的网站服务器并输入

ruby -v

ruby 1.8.7 (2010-08-16 patchlevel 302) [x86_64-linux]. ruby 1.8.7(2010-08-16 patchlevel 302)[x86_64-linux]。

rails -v

Rails 2.3.5 Rails 2.3.5

It appears Ruby and Rails are already installed (Older versions than I require, as I need ruby 1.9.3 and Rails 3.2) If I'm not mistaken it seems like my host 'supports' rails (why else would it already have it installed :P). 似乎已经安装了Ruby和Rails(比我需要的旧版本,因为我需要ruby 1.9.3和Rails 3.2)如果我没有弄错,好像我的主机'支持'rails'(为什么它已经安装了它) :P)。

How should I go about deploying my application directly onto my companies website? 我应该如何将我的应用程序直接部署到我公司的网站上?

Pick up a copy of Agile Web Development with Rails, Third Edition and read what it says about deployment. 使用Rails,第三版获取Agile Web Development的副本,并阅读有关部署的内容。 That should get you started. 这应该让你开始。 There's more info required than can be put in a SO answer. 需要的信息比SO答案要多。

Heroku is an awesome service but the ease of deploying to Heroku has given you a skewed view of what is involved in hosting your own rails website. Heroku是一项非常棒的服务,但是部署到Heroku的简易性使您对托管自己的rails网站所涉及的内容有了不正确的看法。 Heroku has shielded you from a lot of the hard parts. Heroku已经将你从许多困难部分中拯救出来。

For example, just because ruby and rails is installed does not necessarily mean you can host a production rails website. 例如,仅仅因为安装ruby和rails并不一定意味着您可以托管生产rails网站。 You'll need a rails specific web server (for example nginx and passenger, unicorn, etc). 您将需要特定于rails的Web服务器(例如nginx和passenger,unicorn等)。 You also need a database (MySQL or Postgres) assuming your web app uses one. 假设您的网络应用使用一个数据库,您还需要一个数据库(MySQL或Postgres)。 Also, as you said you need to upgrade the versions of ruby and rails. 另外,正如您所说,您需要升级ruby和rails的版本。

That's just to get the server setup. 这只是为了获得服务器设置。 After that you can get to the deployment part. 之后,您可以进入部署部分。 Capistrano seems to be the most popular choice right now. Capistrano似乎是目前最受欢迎的选择。

Take a look at this railscast episode on deploying to a virtual private server for a very good overview of what is involved. 看看这个关于部署到虚拟专用服务器的railscast剧集 ,以便对所涉及的内容进行非常好的概述。 It also briefly goes into Capistrano as well. 它也简要介绍了卡皮斯特拉诺。 It's not a free episode but I feel it's definitly worth the money. 这不是一个免费的插曲,但我觉得它绝对物有所值。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 我无法通过Mina Deployment部署我的Rails应用程序 - I can't deploy my rails app via mina deploy 我可以将数据库保留在本地网络上,但可以在托管服务上部署Rails应用程序吗? - Can I keep my database on my local network but deploy my rails app on a hosting service? 如何在Rails中基于范围的多租户应用程序中创建可跨公司的代理模型 - How do I create an Agent model that can spans across Companies in a scope based multi tenancy app in Rails 如何在没有人工干预的情况下直接从Rails应用程序打印PDF? - How can I print a PDF directly from my rails app without human intervention? 如何使用Rails应用程序干净地部署RSpec和Cucumber HTML结果? - How can I cleanly deploy RSpec & Cucumber HTML results with my Rails app? 如何使我的Rails应用程序/代码库可自定义以将其部署到其他站点 - How can I make my Rails app / codebase customisable to deploy it as different sites 如何将Twitter数据直接拉入我的网站? - How can I pull twitter data directly into my website? 当我尝试部署Rails应用程序时,这里出现什么问题? - What is the issue here when I try to deploy my rails app? 当我将Rails应用程序部署到heroku时,外键消失了 - When I deploy my rails app to heroku a foreign key disappears 如何解决将 Rails 应用程序部署到 Heroku 的问题? - How can I solve this trouble to deploy a Rails App to Heroku?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM