Setting up a local environment

Discussion in 'Install/Configuration' started by palb, Jul 16, 2007.

  1. palb

    palb New Member

    How do I set up a local environment for developing in Rails? Can I set something similar to what I use in Apache like <Directory "/path_to_my_rails_app/app"></Directory>?
  2. mistwang

    mistwang LiteSpeed Staff

    Not sure what you want exactly.
    If you want to limit access to a Rails application, you can set that in the context configuration.
  3. palb

    palb New Member

    I'm not so good with Virtual Hosting. What I want is to set up different Rails apps on my machine that I only use for developing purposes. I suspected context is the answer.
  4. mistwang

    mistwang LiteSpeed Staff

    Yes, you can do that.
  5. palb

    palb New Member

    Thank you for your help.

    I can't get it working. Do I need to do something special regarding Rails? And should my location point to the /public folder in the app?
  6. mistwang

    mistwang LiteSpeed Staff

    Please follow our wikis, I think there are enough resource available on this topic.
  7. palb

    palb New Member

    I'm trying to do that. :)

    I'm stuck at Virtual Host Root, Config File, Enable Scripts/ExtApps, Restrained, that has to be set. I don't think the docs match the Wiki all the way. I know how to run Apache and Mongrel, so I'll soon get back to that if I don't get going with Litespeed.
  8. mistwang

    mistwang LiteSpeed Staff

    Checkout "PickleOnion's LiteSpeed tutorial" with screen shots at the bottom of our Wiki.
  9. palb

    palb New Member

    Starting to read now. This looks better. Thanks :)
  10. palb

    palb New Member

    Stuck on where to set the variable $VH_NAME? I've missed it or it doesn't say. It's supposed to be the name set to the Virtual Host. That I get. Is that the same as Member Virtual Hosts or is it under the actual Virtual Host?
  11. palb

    palb New Member

    Can't get this to work. I think you need some work on your documentation. Even the seemingly more complex Apache+mongrel was easier. :-(
  12. mistwang

    mistwang LiteSpeed Staff

  13. palb

    palb New Member

    That's what I'm trying to do :)

    I don't think I'm trying something to difficult. I'm just trying to get it started so I can develop, not act as a server to the net. Maybe my problem is Virtual Hosting, as that is my week spot. If I just plan to use it locally do I really need VH?
  14. palb

    palb New Member

    I can't add a Virtual Host Root. The server runs as nobody but my Rails app runs as me, and located under my home directory (Mac OS 10.4.9). Even though I run it locally I don't want to run the server with anything else than nobody, www, or similar. What can I do to get this up and running?
  15. palb

    palb New Member

    I give up, for now. Very promising, but not that easy as you claim. Would be nice with one smooth and easy server for both Rails and PHP. But now I can't get php to work either. When trying the phpinfo it doesn't get the page. It did before, but not after I reinstalled lsws.

    To bad, but I need to get back to work with Rails+Apache+Mongrel. If you update the documentation I might have a look at it again. I think you would benefit to get help from a consultant in design and communications.
  16. PSS

    PSS Member

    The logical solution is to chown your rails files and directories to nobody. In localhost developement environment the web server is still a web server, even if it serves just localhost.

    Litespeed is very easy. Just do not think Apache.
  17. palb

    palb New Member

    Yes, of course that's a solution. It's just so much easier to keep the app under me as user. Then you can easily add or delete files in the file system directly. With Apache this is easy to set up. I thought you understood how apache can deal with this when I first asked. This is my goal, to get a setup with me being able to deal with my app under me as user. In this case I prefere to think Apache. Can Litespeed do this?
  18. mistwang

    mistwang LiteSpeed Staff

    In your case, I think the best choice for you is to run the server as your own user ID and only bind listener to localhost, so the server is only accessible from that machine.

    If you want to run the server as nobody and store everything in your home directory, you have give read permission of your home directory to nobody user or group.

    Apache and mongrel talk to each other via socket, does not have this requirement.
  19. palb

    palb New Member

    I'll give it a new try and install it with me as user. Thank you for your help.:)
  20. palb

    palb New Member

    I don't understand how to configure the server for my needs. I believe you have many potential users of Lsws with similar needs that also get stuck. I would welcome an overview off the server admin UI and the documentation.

Share This Page