How to restart an app under Passenger

Hello,

I'm running a rails app on Dreamhost, which uses Passenger. Sometimes I have a very tiny change to make in my code, and have it take effect immediately. However I can't figure out how to trigger Passenger to realize that I've changed my code.

The only thing I know how to do that works is to re-deploy my application via capistrano, which does a full SVN export to a brand- new directory, which of course completely replaces the entire rails app directory structure with a new one. Apparently Passenger figures that out.

However I have not been able to figure out a single smaller step that Passenger will notice. I've even tried "touch"ing the entire directory structure with the current date/time, and Passenger seems to happily ignore that.

Any ideas?

Thanks, Avram

touch tmp/restart.txt

However I can’t figure out how to trigger Passenger to

realize that I’ve changed my code.

Any ideas?

touch tmp/restart.txt

On my system passenger seems to automatically restart the server if tmp/restart.txt exists, then it deletes it. So all I have to do is have an empty tmp/restart.txt locally and when I deploy changes (I use rshell) restart.txt is transferred as it does not exist on the server. The server restarts and all is well.

This may not work for all as when I was investigating this I did find documentation that suggested the restart.txt was tested but not deleted. If your system works like this then you will have to touch it instead.

Colin

Just wanted to thank you both. Don't know why I was unable to find this answer anywhere else.

However I can’t figure out how to trigger Passenger to

realize that I’ve changed my code.

Any ideas?

touch tmp/restart.txt

On my system passenger seems to automatically restart the server if tmp/restart.txt exists, then it deletes it. So all I have to do is have an empty tmp/restart.txt locally and when I deploy changes (I use rshell) restart.txt is transferred as it does not exist on the server. The server restarts and all is well.

I meant rsync of course, not rshell, fingers ignoring brain again.

Avram Dorfman wrote:

Hello,

I'm running a rails app on Dreamhost, which uses Passenger. Sometimes I have a very tiny change to make in my code, and have it take effect immediately. However I can't figure out how to trigger Passenger to realize that I've changed my code.

The only thing I know how to do that works is to re-deploy my application via capistrano, which does a full SVN export to a brand- new directory, which of course completely replaces the entire rails app directory structure with a new one. Apparently Passenger figures that out.

However I have not been able to figure out a single smaller step that Passenger will notice. I've even tried "touch"ing the entire directory structure with the current date/time, and Passenger seems to happily ignore that.

Any ideas?

Thanks, Avram

Hi, I was encountering some issues in uploading my application in dreamhost when i saw your post in this. I'm also using dreamhost with passenger. I followed the steps given, to upload my application into the server but it says "Ruby on Rails application could not be started".... What might be the problem(The application runs perfectly in my system) I'm a newbie to rails , your help is much appreciated. It is much urgent. Please help. Thanks in advance Preethi