Hi all, can you recommend me which web server config to use for developing rails on windows machine. I tried webrick, which is good but it''s annoying because console window is in taskbar for every site running and it have to be started manually. Apache with CGI is to slow and using FastCGI on the other side brings me lot of problems, like randomly not working RoR sites. Any help is appreciated. Thanx, Bojan -- Bojan Mihelac Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com -> tools, scripts, tricks from our code lab: http://source.mihelac.org
There are some great essays on the topic: http://duncandavidson.com/ Erik. Bojan Mihelac schreef:> Hi all, > can you recommend me which web server config to use for developing > rails on windows machine. I tried webrick, which is good but it''s > annoying because console window is in taskbar for every site running > and it have to be started manually. Apache with CGI is to slow and > using FastCGI on the other side brings me lot of problems, like > randomly not working RoR sites. > Any help is appreciated. > > Thanx, > Bojan >
Hi, Bojan, give SCGI with Apache VirtualHosts a try. I''m runnning this on Server 2003 with good results. A search on http://www.ruby-forum.com or the gmane archives of this mailing list would help. Regards Jan Bojan Mihelac wrote:> Hi all, > can you recommend me which web server config to use for developing > rails on windows machine. I tried webrick, which is good but it''s > annoying because console window is in taskbar for every site running > and it have to be started manually. Apache with CGI is to slow and > using FastCGI on the other side brings me lot of problems, like > randomly not working RoR sites. > Any help is appreciated. > > Thanx, > Bojan >
Kevin Olbrich
2006-Jan-11 13:38 UTC
[Rails] Re: Recommend server for developing RoR on win
Instantrails 1.0 supports SCGI and Apache out of the box. It works pretty well, but you still get the console window for the SCGI server. If you ask Curt nicely he might be able to setup InstantRails to use rubyw.exe instead of ruby.exe to run the server scripts. That would hide the windows, but you would probably need to use the task manager to kill the processes when you didn''t need them anymore. _Kevin -- Posted via http://www.ruby-forum.com/.
Bojan Mihelac
2006-Jan-11 15:43 UTC
[Rails] Re: Recommend server for developing RoR on win
Kevin Olbrich wrote:> Instantrails 1.0 supports SCGI and Apache out of the box. It works > pretty well, but you still get the console window for the SCGI server. > > If you ask Curt nicely he might be able to setup InstantRails to use > rubyw.exe instead of ruby.exe to run the server scripts. That would > hide the windows, but you would probably need to use the task manager to > kill the processes when you didn''t need them anymore. > > _Kevin > >Thanks for both answers. I have already Apache and MySql installed with bunch of apps and sites running so I would like to avoid double processes. I am curently evaluating SCGI solution and would post here how it is going. I would not like to learn working with any more apps if it is not really needed - the Ruby and RoR are enough :) -- Bojan Mihelac Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com -> tools, scripts, tricks from our code lab: http://source.mihelac.org
Hi Jan. Thanks for answer. I tried with SCGI following instructions from www.zedshaw.com/projects/*scgi*_*rails*/. However when I start service, for http://127.0.0.1:9999/ I receive blank page and scgi.log adds "[ERR][5456] Malformed request, does not end with '',''". When config for Apache2 is added then the error is: Recognition failed for "/" in routing.rb. Did you have to change .htaccess or some other file in Rails application directory? Any advice? Bojan Jan Prill wrote:> Hi, Bojan, > > give SCGI with Apache VirtualHosts a try. I''m runnning this on Server > 2003 with good results. A search on http://www.ruby-forum.com or the > gmane archives of this mailing list would help. > > Regards > Jan > > Bojan Mihelac wrote: > >> Hi all, >> can you recommend me which web server config to use for developing >> rails on windows machine. I tried webrick, which is good but it''s >> annoying because console window is in taskbar for every site running >> and it have to be started manually. Apache with CGI is to slow and >> using FastCGI on the other side brings me lot of problems, like >> randomly not working RoR sites. >> Any help is appreciated. >> >> Thanx, >> Bojan >> > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >-- Bojan Mihelac Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com -> tools, scripts, tricks from our code lab: http://source.mihelac.org -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060111/8c0fdecd/attachment.html
Try RadRails! It gives you not only a great development Interface (yes, it is an IDE) but also ways to start/stop as many webrick instances as you want (for one or more projects) and it also provides simpler ways to run generators, etc... Rubists don''t like IDE''s, but that is mostly prejudice. RadRails is a nice IDE for Ruby. You can do everything from the IDE: running generators, launching webrick, browsing your app and dealing with CVS or SVN. For browsing I prefer Firefox, though. Regards, Marcelo Bello On 1/11/06, Bojan Mihelac <lists@mihelac.org> wrote:> > Hi all, > can you recommend me which web server config to use for developing rails > on windows machine. I tried webrick, which is good but it''s annoying > because console window is in taskbar for every site running and it have > to be started manually. Apache with CGI is to slow and using FastCGI on > the other side brings me lot of problems, like randomly not working RoR > sites. > Any help is appreciated. > > Thanx, > Bojan > > -- > Bojan Mihelac > Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com > -> tools, scripts, tricks from our code lab: http://source.mihelac.org > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060111/00a8ce28/attachment.html
Bojan, Are you by chance running rails with SCGI on port 9999 and then trying to access your application on port 9999 with your web browser directly? If so then think for a few minutes. Your browser understands HTTP right? SCGI is running on 9999. SCGI is not HTTP. Think. What happens when you tell your browser to go to port 9999? Does it use HTTP? Probably. Does SCGI understand HTTP? Not at all. Try going to the port your web server is on with your web browser. Zed A. Shaw http://www.zedshaw.com/ On Wed, 11 Jan 2006 17:23:30 +0100 Bojan Mihelac <lists@mihelac.org> wrote:> Hi Jan. > Thanks for answer. > I tried with SCGI following instructions from > www.zedshaw.com/projects/*scgi*_*rails*/. > However when I start service, for http://127.0.0.1:9999/ I receive > blank page and scgi.log adds "[ERR][5456] Malformed request, does not > end with '',''". When config for Apache2 is added then the error is: > Recognition failed for "/" in routing.rb. > > Did you have to change .htaccess or some other file in Rails > application directory? Any advice? > > Bojan > > Jan Prill wrote: > > Hi, Bojan, > > > > give SCGI with Apache VirtualHosts a try. I''m runnning this on > > Server 2003 with good results. A search on > > http://www.ruby-forum.com or the gmane archives of this mailing > > list would help. > > > > Regards > > Jan > > > > Bojan Mihelac wrote: > > > >> Hi all, > >> can you recommend me which web server config to use for developing > >> rails on windows machine. I tried webrick, which is good but it''s > >> annoying because console window is in taskbar for every site > >> running and it have to be started manually. Apache with CGI is to > >> slow and using FastCGI on the other side brings me lot of > >> problems, like randomly not working RoR sites. > >> Any help is appreciated. > >> > >> Thanx, > >> Bojan > >> > > > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > > > > > > > > -- > Bojan Mihelac > Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com > -> tools, scripts, tricks from our code lab: http://source.mihelac.org > >
Thanks for answer Zed. Yes, it was not very smart move, I was desperate with "Routing Error \n Recognition failed for "/"" errors (and many others I received in last days) so I tried talking to SCGI like its WebRick server :) This is my config in Apache2 (commented are commands for FCGI which I at last get it working ok)> LoadModule scgi_module modules/mod_scgi.so > .... > <VirtualHost *> > ServerName rails.bojan > DocumentRoot "D:/rdocs/test/public/" > AccessFileName .htaccess > SCGIMount / 127.0.0.1:9999 > <LocationMatch \..+$> > #don''t handle those with SCGI > SCGIHandler Off > </LocationMatch> > <Directory D:/rdocs/test/public/> > Options +FollowSymLinks > Order allow,deny > allow from all > </Directory> > #<Directory "D:/rdocs/test/public/"> > #Options ExecCGI FollowSymLinks > #AllowOverride all > #Allow from all > #Order allow,deny > #AddHandler cgi-script .cgi > #AddHandler fastcgi-script .fcgi > #</Directory> > </VirtualHost>and these is scgi.yaml in config folder> --- > :host: 127.0.0.1 > :password: yGaY8/ZiZcmsQ > :port: 9999 > :logfile: log/scgi.log > :config: config/scgi.yaml > :control_url: druby://127.0.0.1:8999 > :disable_signals: true > :env: developmentMaybe you can see what''s wrong there, it''s seems everything is ok. best regards, Bojan Zed A. Shaw wrote:> Bojan, > > Are you by chance running rails with SCGI on port 9999 and then trying > to access your application on port 9999 with your web browser directly? > > If so then think for a few minutes. Your browser understands HTTP > right? SCGI is running on 9999. SCGI is not HTTP. Think. What > happens when you tell your browser to go to port 9999? Does it use > HTTP? Probably. Does SCGI understand HTTP? Not at all. > > Try going to the port your web server is on with your web browser. > > Zed A. Shaw > http://www.zedshaw.com/ > > > On Wed, 11 Jan 2006 17:23:30 +0100 > Bojan Mihelac <lists@mihelac.org> wrote: > > >> Hi Jan. >> Thanks for answer. >> I tried with SCGI following instructions from >> www.zedshaw.com/projects/*scgi*_*rails*/. >> However when I start service, for http://127.0.0.1:9999/ I receive >> blank page and scgi.log adds "[ERR][5456] Malformed request, does not >> end with '',''". When config for Apache2 is added then the error is: >> Recognition failed for "/" in routing.rb. >> >> Did you have to change .htaccess or some other file in Rails >> application directory? Any advice? >> >> Bojan >> >> Jan Prill wrote: >> >>> Hi, Bojan, >>> >>> give SCGI with Apache VirtualHosts a try. I''m runnning this on >>> Server 2003 with good results. A search on >>> http://www.ruby-forum.com or the gmane archives of this mailing >>> list would help. >>> >>> Regards >>> Jan >>> >>> Bojan Mihelac wrote: >>> >>> >>>> Hi all, >>>> can you recommend me which web server config to use for developing >>>> rails on windows machine. I tried webrick, which is good but it''s >>>> annoying because console window is in taskbar for every site >>>> running and it have to be started manually. Apache with CGI is to >>>> slow and using FastCGI on the other side brings me lot of >>>> problems, like randomly not working RoR sites. >>>> Any help is appreciated. >>>> >>>> Thanx, >>>> Bojan >>>> >>>> >>> _______________________________________________ >>> Rails mailing list >>> Rails@lists.rubyonrails.org >>> http://lists.rubyonrails.org/mailman/listinfo/rails >>> >>> >>> >>> >> -- >> Bojan Mihelac >> Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com >> -> tools, scripts, tricks from our code lab: http://source.mihelac.org >> >> >> > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > > >-- Bojan Mihelac Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com -> tools, scripts, tricks from our code lab: http://source.mihelac.org -------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060112/bb6e5338/attachment.html
Hi, Bojan, looks not so bad indeed. Haven''t used it for quite some time (using webrick for development myself) but this is one configuration that definitly has worked. Not much different. Would you try to take the quotes of the DocumentRoot? Regards Jan <VirtualHost *:8080> AddDefaultCharset utf-8 ServerName www.blauton.de DocumentRoot f:/home/jan/workspace/blauton/public/ ErrorDocument 500 /500.html ErrorDocument 404 /404.html # handle all requests throug SCGI SCGIMount / 127.0.0.1:9999 # matches locations with a dot following at least one more characters, that is, things like *,html, *.css, *.js, which should be delivered directly from the filesystem <LocationMatch \..+$> # don''t handle those with SCGI SCGIHandler Off </LocationMatch> <Directory f:/home/jan/workspace/blauton/public/> Options +FollowSymLinks Order allow,deny allow from all </Directory> </VirtualHost> --- :host: 127.0.0.1 :password: ### :port: 9999 :logfile: log/scgi.log :config: config/scgi.yaml :control_url: druby://127.0.0.1:8999 :disable_signals: true :env: development Bojan Mihelac wrote:> Thanks for answer Zed. Yes, it was not very smart move, I was > desperate with "Routing Error \n Recognition failed for "/"" errors > (and many others I received in last days) so I tried talking to SCGI > like its WebRick server :) > This is my config in Apache2 (commented are commands for FCGI which I > at last get it working ok) > >> LoadModule scgi_module modules/mod_scgi.so >> .... >> <VirtualHost *> >> ServerName rails.bojan >> DocumentRoot "D:/rdocs/test/public/" >> AccessFileName .htaccess >> SCGIMount / 127.0.0.1:9999 >> <LocationMatch \..+$> >> #don''t handle those with SCGI >> SCGIHandler Off >> </LocationMatch> >> <Directory D:/rdocs/test/public/> >> Options +FollowSymLinks >> Order allow,deny >> allow from all >> </Directory> >> #<Directory "D:/rdocs/test/public/"> >> #Options ExecCGI FollowSymLinks >> #AllowOverride all >> #Allow from all >> #Order allow,deny >> #AddHandler cgi-script .cgi >> #AddHandler fastcgi-script .fcgi >> #</Directory> >> </VirtualHost> > > and these is scgi.yaml in config folder > >> --- >> :host: 127.0.0.1 >> :password: yGaY8/ZiZcmsQ >> :port: 9999 >> :logfile: log/scgi.log >> :config: config/scgi.yaml >> :control_url: druby://127.0.0.1:8999 >> :disable_signals: true >> :env: development > > Maybe you can see what''s wrong there, it''s seems everything is ok. > > best regards, > Bojan > > Zed A. Shaw wrote: > >>Bojan, >> >>Are you by chance running rails with SCGI on port 9999 and then trying >>to access your application on port 9999 with your web browser directly? >> >>If so then think for a few minutes. Your browser understands HTTP >>right? SCGI is running on 9999. SCGI is not HTTP. Think. What >>happens when you tell your browser to go to port 9999? Does it use >>HTTP? Probably. Does SCGI understand HTTP? Not at all. >> >>Try going to the port your web server is on with your web browser. >> >>Zed A. Shaw >>http://www.zedshaw.com/ >> >> >>On Wed, 11 Jan 2006 17:23:30 +0100 >>Bojan Mihelac <lists@mihelac.org> wrote: >> >> >> >>>Hi Jan. >>>Thanks for answer. >>>I tried with SCGI following instructions from >>>www.zedshaw.com/projects/*scgi*_*rails*/. >>>However when I start service, for http://127.0.0.1:9999/ I receive >>>blank page and scgi.log adds "[ERR][5456] Malformed request, does not >>>end with '',''". When config for Apache2 is added then the error is: >>>Recognition failed for "/" in routing.rb. >>> >>>Did you have to change .htaccess or some other file in Rails >>>application directory? Any advice? >>> >>>Bojan >>> >>>Jan Prill wrote: >>> >>> >>>>Hi, Bojan, >>>> >>>>give SCGI with Apache VirtualHosts a try. I''m runnning this on >>>>Server 2003 with good results. A search on >>>>http://www.ruby-forum.com or the gmane archives of this mailing >>>>list would help. >>>> >>>>Regards >>>>Jan >>>> >>>>Bojan Mihelac wrote: >>>> >>>> >>>> >>>>>Hi all, >>>>>can you recommend me which web server config to use for developing >>>>>rails on windows machine. I tried webrick, which is good but it''s >>>>>annoying because console window is in taskbar for every site >>>>>running and it have to be started manually. Apache with CGI is to >>>>>slow and using FastCGI on the other side brings me lot of >>>>>problems, like randomly not working RoR sites. >>>>>Any help is appreciated. >>>>> >>>>>Thanx, >>>>>Bojan >>>>> >>>>> >>>>> >>>>_______________________________________________ >>>>Rails mailing list >>>>Rails@lists.rubyonrails.org >>>>http://lists.rubyonrails.org/mailman/listinfo/rails >>>> >>>> >>>> >>>> >>>> >>>-- >>>Bojan Mihelac >>>Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com >>>-> tools, scripts, tricks from our code lab: http://source.mihelac.org >>> >>> >>> >>> >>_______________________________________________ >>Rails mailing list >>Rails@lists.rubyonrails.org >>http://lists.rubyonrails.org/mailman/listinfo/rails >> >> >> >> >> > > >-- >Bojan Mihelac >Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com >-> tools, scripts, tricks from our code lab: http://source.mihelac.org > > >------------------------------------------------------------------------ > >_______________________________________________ >Rails mailing list >Rails@lists.rubyonrails.org >http://lists.rubyonrails.org/mailman/listinfo/rails > >
Hi Jan, all same without quotes. Should do clean install of apache/mysql/scgi to see where the problem is. best, Bojan Jan Prill wrote:> Hi, Bojan, > > looks not so bad indeed. Haven''t used it for quite some time (using > webrick for development myself) but this is one configuration that > definitly has worked. Not much different. Would you try to take the > quotes of the DocumentRoot? > > Regards > Jan > > <VirtualHost *:8080> > AddDefaultCharset utf-8 > ServerName www.blauton.de > DocumentRoot f:/home/jan/workspace/blauton/public/ > ErrorDocument 500 /500.html > ErrorDocument 404 /404.html > # handle all requests throug SCGI > SCGIMount / 127.0.0.1:9999 > # matches locations with a dot following at least one more > characters, that is, things like *,html, *.css, *.js, which should > be delivered directly from the filesystem > <LocationMatch \..+$> > # don''t handle those with SCGI > SCGIHandler Off > </LocationMatch> > <Directory f:/home/jan/workspace/blauton/public/> > Options +FollowSymLinks > Order allow,deny > allow from all > </Directory> > </VirtualHost> > > --- > :host: 127.0.0.1 > :password: ### > :port: 9999 > :logfile: log/scgi.log > :config: config/scgi.yaml > :control_url: druby://127.0.0.1:8999 > :disable_signals: true > :env: development > > Bojan Mihelac wrote: > >> Thanks for answer Zed. Yes, it was not very smart move, I was >> desperate with "Routing Error \n Recognition failed for "/"" errors >> (and many others I received in last days) so I tried talking to SCGI >> like its WebRick server :) >> This is my config in Apache2 (commented are commands for FCGI which I >> at last get it working ok) >> >>> LoadModule scgi_module modules/mod_scgi.so >>> .... >>> <VirtualHost *> >>> ServerName rails.bojan >>> DocumentRoot "D:/rdocs/test/public/" >>> AccessFileName .htaccess >>> SCGIMount / 127.0.0.1:9999 >>> <LocationMatch \..+$> >>> #don''t handle those with SCGI >>> SCGIHandler Off >>> </LocationMatch> >>> <Directory D:/rdocs/test/public/> >>> Options +FollowSymLinks >>> Order allow,deny >>> allow from all >>> </Directory> #<Directory "D:/rdocs/test/public/"> >>> #Options ExecCGI FollowSymLinks >>> #AllowOverride all >>> #Allow from all >>> #Order allow,deny >>> #AddHandler cgi-script .cgi >>> #AddHandler fastcgi-script .fcgi >>> #</Directory> >>> </VirtualHost> >> >> and these is scgi.yaml in config folder >> >>> --- >>> :host: 127.0.0.1 >>> :password: yGaY8/ZiZcmsQ >>> :port: 9999 >>> :logfile: log/scgi.log >>> :config: config/scgi.yaml >>> :control_url: druby://127.0.0.1:8999 >>> :disable_signals: true >>> :env: development >> >> Maybe you can see what''s wrong there, it''s seems everything is ok. >> >> best regards, >> Bojan >> >> Zed A. Shaw wrote: >> >>> Bojan, >>> >>> Are you by chance running rails with SCGI on port 9999 and then trying >>> to access your application on port 9999 with your web browser directly? >>> >>> If so then think for a few minutes. Your browser understands HTTP >>> right? SCGI is running on 9999. SCGI is not HTTP. Think. What >>> happens when you tell your browser to go to port 9999? Does it use >>> HTTP? Probably. Does SCGI understand HTTP? Not at all. >>> >>> Try going to the port your web server is on with your web browser. >>> >>> Zed A. Shaw >>> http://www.zedshaw.com/ >>> >>> >>> On Wed, 11 Jan 2006 17:23:30 +0100 >>> Bojan Mihelac <lists@mihelac.org> wrote: >>> >>> >>> >>>> Hi Jan. >>>> Thanks for answer. >>>> I tried with SCGI following instructions from >>>> www.zedshaw.com/projects/*scgi*_*rails*/. >>>> However when I start service, for http://127.0.0.1:9999/ I receive >>>> blank page and scgi.log adds "[ERR][5456] Malformed request, does not >>>> end with '',''". When config for Apache2 is added then the error is: >>>> Recognition failed for "/" in routing.rb. >>>> >>>> Did you have to change .htaccess or some other file in Rails >>>> application directory? Any advice? >>>> >>>> Bojan >>>> >>>> Jan Prill wrote: >>>> >>>>> Hi, Bojan, >>>>> >>>>> give SCGI with Apache VirtualHosts a try. I''m runnning this on >>>>> Server 2003 with good results. A search on >>>>> http://www.ruby-forum.com or the gmane archives of this mailing >>>>> list would help. >>>>> >>>>> Regards >>>>> Jan >>>>> >>>>> Bojan Mihelac wrote: >>>>> >>>>> >>>>>> Hi all, >>>>>> can you recommend me which web server config to use for >>>>>> developing rails on windows machine. I tried webrick, which is >>>>>> good but it''s annoying because console window is in taskbar for >>>>>> every site >>>>>> running and it have to be started manually. Apache with CGI is to >>>>>> slow and using FastCGI on the other side brings me lot of >>>>>> problems, like randomly not working RoR sites. >>>>>> Any help is appreciated. >>>>>> >>>>>> Thanx, >>>>>> Bojan >>>>>> >>>>>> >>>>> _______________________________________________ >>>>> Rails mailing list >>>>> Rails@lists.rubyonrails.org >>>>> http://lists.rubyonrails.org/mailman/listinfo/rails >>>>> >>>>> >>>>> >>>>> >>>> -- >>>> Bojan Mihelac >>>> Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com >>>> -> tools, scripts, tricks from our code lab: http://source.mihelac.org >>>> >>>> >>>> >>> _______________________________________________ >>> Rails mailing list >>> Rails@lists.rubyonrails.org >>> http://lists.rubyonrails.org/mailman/listinfo/rails >>> >>> >>> >>> >>> >> >> >> -- >> Bojan Mihelac >> Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com >> -> tools, scripts, tricks from our code lab: http://source.mihelac.org >> >> >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> Rails mailing list >> Rails@lists.rubyonrails.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> >> > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >-- Bojan Mihelac Informatika Mihelac, Bojan Mihelac s.p. | www.informatikamihelac.com -> tools, scripts, tricks from our code lab: http://source.mihelac.org