I've consulted wikis, old threads, forums, everything, in order to
understand/find a way to deploy RoR with minimum effort.
I've developed it using WebBrick to check functionality; now I want to
deploy it in a net apache server (using plesk) which I am client of.
It seems plesk supports Ruby, and I just need to click on a "fastCGI"
checkbox to have such support.
Considering Ruby and Rails are installed and running properly in
server, how to deploy the app? Why doesn't a simple copy/paste work
(it is always wanted a known repository)? What changes should be made
in code side? There are some differente alternatives in Ruby site, but
always forcing some configs on server side. Without make any changes
in server, what is the proper way of doing it?
I am always getting these errors:
[Tue Mar 23 12:56:33 2012] [warn] [client xxxxx] (104)Connection reset
by peer: mod_fcgid: error reading data from FastCGI server
[Tue Mar 23 12:56:33 2012] [error] [client xxxxx] Premature end of
script headers: dispatch.fcgi
which seems not detailed enough to understand what to do next. Some
say it's RoR missing gems, others say it's because of file
permissions, also .htaccess hidden file overriding the proper one...
I've checked and tested most of it without success.
Thanks in advance.
Can you to run your app in Heroku? Is very easy.
If you want to have a custom or full control of the environment, you can to read the book Deploying Rails.
Using FastCGI to run your Rails application has been more or less
abandoned. As another poster said, your best bet is to probably get
up and running on Heroku. If you can't do that, you'll want to look
at installing Passenger (AKA mod_rails).
A web host that is suggesting that you use FastCGI to serve your Rails
apps in 2012 is wasting your time.
+1 with Heroku
I don't *think* a Rails application will work on FastCGI. For using
apache, you will need Phusion Passenger. However, I don't know if
your hosting solution supports it or will do, you should ask.
If Passenger is supported, then you only need to define a virtual host
and point the DocumentRoot to the Rails app public directory.
Considerng all your dependencies are installed, you can just copy your
code to the directory defined in the virtual host.
There are other solutions, but they don't require "minimum effort".
If you can't solve this with your current hosting, I would consider
Heroku, as Fernando and Paul suggested.
For what its worth, Heroku is not just for every app, and not because
it doesn't support it but because pricing can get too high too soon,
depending on your needs.
If Heroku doesn't fit your needs for any reason, I would recommend a
Hope this help.
FastCGI used to be a way to deploy Rails a couple of years ago. What are you allowed to do in the server? And yes there is a copy/paste way to deploy but is not recommended. Please post more details about your hosting solution.
Server uses Plesk; as far as I know, I am only able to use a file explorer, or access files via ftp. Even with the proper alternatives, please explain what’s needed to make that copy/past deployment.
Thanks in advance
If you only have access to the Plesk panel, you should get another hosting service specially since the one you are using seems dated and performance will be sub-standard and copy/paste solutions dont involve FastCGI. Try heroku first, is initially free.