udai kudikyala
2007-May-24 20:47 UTC
[Instantrails-users] Create a virtual host using Instant Rails 1.7
Hi, I created a new rails application called demo using Instant Rails 1.7. It runs at the URL http://localhost:3003/blog/ The applications that a packaged with the zip file, cookbook and typo are currenlty the two virtual hosts. I can already run them using the following URLs http://www.mycookbook.com and http://typo/ Now, I want to add my application demo as the third virtual host in development mode. This application for example, could run on the URL http://www.mydemo.com/ What files do I need to modify to set this up? Please help. Thanks Udai -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/instantrails-users/attachments/20070524/e13c21f0/attachment-0001.html
Curt Hibbs
2007-May-24 21:03 UTC
[Instantrails-users] Create a virtual host using Instant Rails 1.7
On 5/24/07, udai kudikyala <udaikudikyala at gmail.com> wrote:> > Hi, > I created a new rails application called demo using Instant Rails 1.7. > It runs at the URL http://localhost:3003/blog/ > > The applications that a packaged with the zip file, cookbook and typo are > currenlty the two virtual hosts. I can already run them using the following > URLs > http://www.mycookbook.com and http://typo/ > Now, I want to add my application demo as the third virtual host in > development mode. > This application for example, could run on the URL http://www.mydemo.com/ > What files do I need to modify to set this up? > >Just pick an unused port (like 3008 or something), and configure your rails app to run there. Edit the apache config file (through the Instant Rails menus) and duplicate the section already in there for eith typo or the cookbook, and then change name and port to match your new app. Finally edit you windows HOSTS file to map the new name to 127.0.0.1 (unless you already have your own DNS server running). Curt -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/instantrails-users/attachments/20070524/fe8e7086/attachment.html
udai kudikyala
2007-May-24 21:51 UTC
[Instantrails-users] Create a virtual host using Instant Rails 1.7
Hi, Thanks for the instant reply : ). THis is what I did 1. Under Rails Applications --> Manage Rail Applications I clicked on the demo (my application) check box and clicked on Configure Startup Mode button In Configure Demo Window I set Runtime mode text box : development Port: 3038 Then I clicked on Edit Apache Config button and added the following text <VirtualHost *> ServerName www.mydemo.com ProxyPass / http://localhost:3028/ ProxyPassReverse / http://localhost:3028 </VirtualHost> Saved this file Then I clicked on the Edit Window Host file and added the following line 127.0.0.1 www.mydemo.com Saved this file and clicked OK button in Configue Demo Window Then I Clicked on Start with Mongrel button in Rails Application Window. Now, I opened IE and typed the URL : http://www.mydemo.com/ It showed me the default page (welcome Aboard Riding the Rails page). I have to physically type http://www.mydemo.com/blog in order to see my application (scaffolding). Blog is the controller for this application. Now, the cookbook application seems to be redirecting to http://www.mycookbook.com/recipe/list by just typing the URL http://www.mycookbook.com This is not hapenning with my application though. I don''t undersand. Any help is appreciated. Thanks again for your help. Udai On 5/24/07, Curt Hibbs <curt.hibbs at gmail.com> wrote:> > On 5/24/07, udai kudikyala <udaikudikyala at gmail.com> wrote: > > > > Hi, > > I created a new rails application called demo using Instant Rails 1.7. > > It runs at the URL http://localhost:3003/blog/ > > > > The applications that a packaged with the zip file, cookbook and typo > > are currenlty the two virtual hosts. I can already run them using the > > following URLs > > http://www.mycookbook.com and http://typo/ > > Now, I want to add my application demo as the third virtual host in > > development mode. > > This application for example, could run on the URL > > http://www.mydemo.com/ > > What files do I need to modify to set this up? > > > > > Just pick an unused port (like 3008 or something), and configure your > rails app to run there. Edit the apache config file (through the Instant > Rails menus) and duplicate the section already in there for eith typo or the > cookbook, and then change name and port to match your new app. > > Finally edit you windows HOSTS file to map the new name to 127.0.0.1(unless you already have your own DNS server running). > > Curt > > _______________________________________________ > Instantrails-users mailing list > Instantrails-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/instantrails-users >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/instantrails-users/attachments/20070524/79f520d4/attachment.html
David Morton
2007-May-25 04:49 UTC
[Instantrails-users] Create a virtual host using Instant Rails 1.7
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On May 24, 2007, at 4:51 PM, udai kudikyala wrote:> Now, the cookbook application seems to be redirecting to > http://www.mycookbook.com/recipe/list by just typing the URL > http://www.mycookbook.com > This is not hapenning with my application though. I don''t undersand. > Any help is appreciated. > Thanks again for your help. >That''s the correct behavior. You have to specify the default action via Rail''s routes mechanism. Look in the config/routes.rb for one of the other applications, or look for docs on rails routing. David Morton Maia Mailguard http://www.maiamailguard.com mortonda at dgrmm.net -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (Darwin) iD8DBQFGVmr3Uy30ODPkzl0RArtYAJwOtq1a9KExuyyFnf3xQ64OS1jTtACgkk/Z qS1L+t6U3PVwkkF99J+x7nI=pJz8 -----END PGP SIGNATURE-----
udai kudikyala
2007-May-25 13:34 UTC
[Instantrails-users] Create a virtual host using Instant Rails 1.7
Thanks for pointing me in the right direction. The cookbook application is using the default index.html page to redirect to the required URL. The Typo application is actually using rails routing (config/routes.rb) to invoke the controller and the action. Well both mechanisms work. I really appreciate your help. Udai On 5/24/07, David Morton <mortonda at dgrmm.net> wrote:> > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > > On May 24, 2007, at 4:51 PM, udai kudikyala wrote: > > > > Now, the cookbook application seems to be redirecting to > > http://www.mycookbook.com/recipe/list by just typing the URL > > http://www.mycookbook.com > > This is not hapenning with my application though. I don''t undersand. > > Any help is appreciated. > > Thanks again for your help. > > > > > That''s the correct behavior. You have to specify the default action > via Rail''s routes mechanism. Look in the config/routes.rb for one of > the other applications, or look for docs on rails routing. > > David Morton > Maia Mailguard http://www.maiamailguard.com > mortonda at dgrmm.net > > > > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.5 (Darwin) > > iD8DBQFGVmr3Uy30ODPkzl0RArtYAJwOtq1a9KExuyyFnf3xQ64OS1jTtACgkk/Z > qS1L+t6U3PVwkkF99J+x7nI> =pJz8 > -----END PGP SIGNATURE----- > _______________________________________________ > Instantrails-users mailing list > Instantrails-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/instantrails-users >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/instantrails-users/attachments/20070525/479cf5b9/attachment.html