Ruby on Rails
Friday, November 9, 2018
somewhat off the topic - but just want to repeat my delight that HatchBox now handle all this server pain for me!
If you do want to check out hatchbox - this link gives me a referral bonus
https://hatchbox.io?via=rob
-- it's kinda like heroku - but they'll configure the server on your choice of host. I use DigitalOcean
I give them a fairly modest amount of money, and they make all this kind of thing very easy.
Adding an extra domain to the app is about three clicks. (app, configuration, type your new domain name, click add) They worry about the ngnix config and all that
I actually have an app like yours which behaves differently according to host. I just have this method in my application controller
def get_host
host = params[:host] || request.host
@host = HostInfo.with(host:host)
end
I use the params[:host] option to simplify local testing. It allows me to test localhost:3000/?host=domain.com
https://hatchbox.io?via=rob
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/3b2f8592-f3c6-4c67-abf8-be2c1f0ef2ad%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment