Separate names with a comma.
Discussion in 'Ruby/Rails' started by palb, Sep 17, 2007.
How do you restart the Rails app when you don't have direct access to the admin area?
try "touch .ls_restart" under the virtual host root directory.
Great. I can't see that there is such a file, but it will of course be created when running touch. What if I upload the file via ftp? Would that give the same effect? It should be much the same, right?
whenever the modified time of that file changes, the rails application will be restarted.
Thanks for fast replies.
Doesn't seems to work. What is supposed to happen? Will LS restart with that at once, or when you try to access the site from the web? Does it matter if the file is owned by someone else that server owner:group and what permission should it have?
Sorry, it only works with Rails app configured this way
Can't get this to work. I think it must be something about my path. How does this look:
#RailsApp <name> <App Path> <Rails Evn> <Children Processes> <RunOnStart>
RailsApp myappname "/public" "development" 4 1
#RailsAppMap <name> <domain> <URI>
RailsAppMap myappname "www.myappname.com" "/"
It's relative to VH_root. That is located under my user directory in /myappname but the server is in /usr/local (Mac OS)
Are you using a Enterprise edition?
No. So that's why. Ok. We're testing LS for our needs and we plan to switch to Enterprise edition if all goes well.
The need to restart the server after uploading new files to the server is not so good and the first negative thing I have to say about LS. I believe you need to address this. Or have I missed some settings in admin
You need to restart the rails application with other rails hosting platform as well. Nothing special for LiteSpeed. With Enterprise edition, uploading a ".ls_restart" file together with the application, it will restarts.
Not with Mongrel if I remember it correctly. And Apache don't need it (though it doesn't run Rails). Or? Why would you need to restart the server when you've made a change in a file like css for example? It doesn't need to be restarted when you add it the first time.
css file is cache by the browser not the server, the default configuration of LSWS tell browser to cache css files. You can turn it off.
Of course it's cached by the browser, if you don't set it to 0.
When I look at the server files, .rhtml and css, they have the correct code. How come LSWS still serves me the old code? Hmm.
No, LSWS does not even serve it, the css is from the browser cache, if you clear the cache and request the file again, you should see that the latest file.
No I don't. As a developer I don't have cache on. I've tested on several browsers on my Mac and PC. However, I now see a strange number in the href for the external css. That's LSWS. Could it be something about compression?
The compressed version should be updated automatically as well. Please test it with command line tool like curl or Lynx.
"lynx -mime_header http://your_url"
I don't have lynx, as it seems. I tried curl but not sure what to fetch. The header says:
HTTP/1.1 200 OK
Content-Type: text/html; charset=utf-8
Set-Cookie: _session_id=115816877ed000ba7353d211be3346af; path=/
Date: Tue, 02 Oct 2007 20:55:16 GMT
Keep-Alive: timeout=5, max=100
Just fetch the css file, see if it is the latest version.