Rails三兩事 A website introduce you ruby&rails and technology news.

6Oct/091

Heroku is a great host for RoR. But still has some problems

Heroku的簡便,其實也造就了他的問題.
因為不是第一次被人推薦了,所以就去官網上看看.
不過,看了就覺得並不是太想用.
除了價格昂貴,再來就是他的優點,其實也是缺點.

Heroku的優點是兩面刃

由於你只要註冊好Heroku,然後 :
sudo gem install heroku
heroku create yourapp

當你要建好專案要上傳 :
git push heroku
就上傳好了

當要做些工作,比如migrate :

heroku domains:add yourdomain.com  #(加網域名,應該是加到DNS?)
heroku rake db:migrate
heroku bundles:capture

可是,他的方便也是不便.
我是不太喜歡一直和Host方溝通,比較喜歡一次就擁有很多自主權.
所以,當有問題,我該寫信去???

問題1, 如果想增加sub domain? 更改MX records,CName,etc...?
問題2, 原先配置為Thin+Nginx. 若想改用其他?
問題3, 目前尚未支援Custom SSL.
問題4, 太貴....
問題5, 還沒想到. 如果你有解答,歡迎討論互動.

就像Xdite說的,在我看來,現在還是Project比較適合. 若要Production,太貴,也不太適合.

--後記 :
初碰Heroku可能面臨問題.
Q : Install?
A : $>sudo gem install heroku

Q : Create?
A : $>git init
$>heroku create

Q : Upload?
A : $>git push heroku YouBranchName(master)

Q : See?
A : $>heroku open

Q : No ssh public key found in /root/.ssh/id_[rd]sa.pub. You may want to specify the full path to the keyfile.
A : ssh-keygen -t rsa

Q : Move Database?
A : $>sudo gem install taps
$>heroku db:push

Q : Rename App?
A : $>git remote rm heroku
$>git remote add git@heroku.com:YOURAPPNAME.git

Q : Manage Custom Gems?
A : 1. Create a file ".gems" under folder
2. Add "yourgem --version x.x.x --source xxxxxxxx" (ex : geokit --version '>=1.5.0' )
Each Gem one line.
3. "git commit -a" & "git push heroku xxx"

Share and Enjoy:
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
Comments (1) Trackbacks (0)
  1. Oh thanks, this is very helpful.


Leave a comment


No trackbacks yet.