passenger

What are the advantages of using Passenger over a Mongrel Cluster?

核能气质少年 提交于 2019-12-06 03:02:26
This is probably the silliest question today but... The Rails team & many others recommend using passenger instead of a mongrel cluster, but I cannot find a clear list of exact benefits / advantages of this or what the potential pitfall are. Just wondering if anyone can help explain this? Also is passenger its own server or does it use mongrel under the hood? Thanks! Before Passenger, Mongrel was the way to go, but a Mongrel cluster can be a nuisance to keep properly tuned. As your application grows in complexity, the memory footprint of each Mongrel instance will expand, and this can eat into

Premature end of script headers: media ( Issue related to :rails app deployment+passenger+ubuntu+apache)

狂风中的少年 提交于 2019-12-06 02:59:14
i just setup a linode server and deploy my rails 3 app on it.its up and running.The problem is that some images are not showing up in the production.locally they are perfectly working.i double checked the log file(production.log) but nothing found.then i check server error.log file that says. [Sat Dec 29 22:54:14 2012] [error] [client 182.177.228.157] Premature end of script headers: media, referer: http://50.116.57.152/app?v=11&o=33 Check out http://50.116.57.152/app?v=11&o=33 for live demo. Thanking in advance. i figured it out.ImageMagick gem was not installed on my linode server and i used

staging and live app with capistrano

十年热恋 提交于 2019-12-06 02:32:53
问题 I thought I'd do a simple yet potentially very useful thing, and create another symlink called live, that points to an arbitrary release, and leave current at the head where it usually is: 20120519235508 20120521004833 20120521024312 <-- live 20120521025150 20120521030449 <-- current I then configured www.mysite.com to hit live/public and stage.mysite.com to hit current/public Unfortunately both hosts seem to run the same app, and not 2 different apps. I've confirmed the httpd.conf has the

How to restart Phusion Passenger + Apache in Production mode on Ubuntu server for Ruby on Rails?

南笙酒味 提交于 2019-12-06 01:31:24
问题 I am having Apache + phusion passenger, I have put RailsEnv production in /etc/apache2/sites-available/default file and have restarted apache but when I am running rails c > Rails.env.production? it gives fales where as for > Rails.env.development? it gives true. Is there any other way to restart passenger as I do think putting "RailsEnv production" in default is the right way ? btw I am using sudo service apache2 restart How to start my ruby on rails app in Production mode with passenger +

Is there an easy way to run Garbage Collection outside of the request cycle in Passenger?

浪子不回头ぞ 提交于 2019-12-05 21:38:21
问题 Unicorn has OobGC rack middleware that can be used to run GC.start after a certain number of requests. Is there a similar sort of thing in Phusion Passenger? 回答1: Phusion Passenger 4 officially introduces an out of band garbage collection mechanism. It's more flexible than Unicorn's by allowing any arbitrary work, not just garbage collection. http://blog.phusion.nl/2013/01/22/phusion-passenger-4-technology-preview-out-of-band-work/ 回答2: Hooking into PhusionPassenger::Rack::RequestHandler

Rails 3.2 f.file_field causes routing error

北慕城南 提交于 2019-12-05 18:22:16
Tested on rails 3.2.12 and 3.2.11. In another rails 3.2.11 project I do not have this issue with f.file_field , but in current one I do and can't find a reason for this strange behaviour, so here is my question. I have a weird problem with update action. Here are relevant parts of code: routes: get "signup" => "users#new", :as => "signup" get "profile" => "users#profile", :as => "profile" resources :users do member do get :activate end end controller: def update @user = User.find(params[:id]) if @user.update_attributes(params[:user]) redirect_to user_path(@user), :notice => t('users_controller

CSS available but not rendering when push to production [Rails app]

▼魔方 西西 提交于 2019-12-05 18:06:46
For some strange reason I cannot get my Rails app to render the CSS files on the server when running in production mode. I am running a Passenger + Nginx setup. When I hit the public URL, I can see the app. The problem is, no styles are being applied. When I use the Chrome dev tools to view the CSS being rendered, I see that the file is present on the server, with all the CSS in it. However, if I look at a specific component, I see something strange: a:-webkit-any-link { color: -webkit-link; text-decoration: underline; cursor: auto; } Everything says "webkit...style". Or "user-agent". I've

Phusion Passenger is currently not serving any applications

狂风中的少年 提交于 2019-12-05 17:14:13
问题 I got error like Phusion Passenger is currently not serving any applications. while trying to restart passenger with passenger-config restart-app command. I googled but most of the answers were only related with deployment. I want to restart passenger in the development environment as I am using vhost. PS. My web server is nginx. 回答1: See my comment here. You need to explicitly specify, where actual Ruby code of a Rails application is located, using passenger_app_root directive, described in

Issue when trying to run passenger on Apache

可紊 提交于 2019-12-05 15:32:34
I am getting this issue when running httpd -t httpd: Syntax error on line 545 of /private/etc/apache2/httpd.conf: Syntax error on line 1 of /private/etc/apache2/other/passenger.conf: Cannot load /Users/sbaidon/.rvm/gems/ruby-2.2.5/gems/passenger-5.3.5/b uildout/apache2/mod_passenger.so into server: dlopen(/Users/sbaidon/.rvm/gems/ruby-2.2.5/gems/passenger-5.3.5/buildout/apache2/mod_passenger.so, 10): no suitable image found. Did find:\n\t/Users/sbaidon/.rv m/gems/ruby-2.2.5/gems/passenger-5.3.5/buildout/apache2/mod_passenger.so: code signature in (/Users/sbaidon/.rvm/gems/ruby-2.2.5/gems

How do I create a resque worker automatically at bootup?

一世执手 提交于 2019-12-05 10:52:17
Ok, I'm making my first ruby app. Who know moving everything over to 'production' is so fugging complicated. So far I've struggled my way through configuring passenger, getting it to run on startup, then getting redis to run on startup. My last task is on startup to add 1 worker. Right now, I have to ssh in and run my rake command rake workers:start . Obviously this is no good when I want to close ssh.. so I just dont really know how or what the next step is. I tried copying resque default config to config.ru and it just blows up Passenger with errors. I also looked into resque-pool which some