简体   繁体   English

在预算紧张的情况下部署小型Rails应用程序的最佳方法?

[英]Best way to deploy a small rails app on a tight budget?

I want to play around with deploying a very small rails application. 我想尝试部署一个非常小的Rails应用程序。

It's for personal use, so there will be very low traffic and the app itself is just a newly generated rails 4 project with a sqlite db at the moment. 它仅供个人使用,因此流量将非常低,该应用程序本身只是一个新生成的带有sqlite db的Rails 4项目。

Currently I have a free AWS instance, a github account with the rails project and a domain. 目前,我有一个免费的AWS实例,一个带有rails项目的github帐户和一个域。

My plan is to follow the amazon guide here: http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/create_deploy_Ruby_rails.html 我的计划是在这里遵循亚马逊指南: http : //docs.aws.amazon.com/elasticbeanstalk/latest/dg/create_deploy_Ruby_rails.html

Is this doable on a free instance or will I need to spend cash on hosting / platform provider? 这在免费实例上可行吗,还是我需要在托管/平台提供商上花费现金?

Ideally I would like to do this for free, or as close to as possible. 理想情况下,我想免费或尽可能地这样做。

Is there a better or easier way to do this? 有更好或更简单的方法可以做到这一点吗?

Thanks for any advice. 感谢您的任何建议。

The AWS Free Tier only lasts a year. AWS免费套餐仅持续一年。 After that you have to pay and it is not very cheap. 之后,您必须付费,而且价格不是很便宜。

You could try out Heroku . 您可以尝试Heroku Running a simple app is free on Heroku. 在Heroku上免费运行一个简单的应用程序。 Perfect for your own hobby projects, can be upscaled when it starts to get real. 非常适合您自己的业余爱好项目,当它开始变得真实时可以进行升级。

I recently tried to find the same thing for a blog. 我最近尝试为博客找到相同的东西。 I found that I didn't qualify for the free instance for AWS because I signed up to S3 years ago. 我发现我没有资格获得AWS免费实例的资格,因为我早在S3年前就注册了。 But that heroku has free development boxes. 但是那个heroku有免费的开发箱。

Basically, you can get this for free: 基本上,您可以免费获得:

  • a host 一个举办方
  • a small database 一个小的数据库

But you can't get this for free: 但是你不能免费得到这个:

  • background processing 后台处理
  • permanent up time 永久的正常运行时间

The up time thing is the biggest problem for me. 正常运行时间对我来说是最大的问题。 Basically if you don't have someone visiting your site regularly, heroku shut it down to re-distribute the cpu cycles. 基本上,如果您没有人定期访问您的网站,heroku会将其关闭以重新分配CPU周期。 It will start up again if you visit the site, but it does take 20-30 seconds. 如果您访问该站点,它将再次启动,但是确实需要20到30秒。

If you want permanent up time, you need to buy a second dyno which will cost $35 a month ish. 如果您想要永久的正常运行时间,则需要购买第二个dyno,每月费用为35美元。

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM