Hii all,
         i am ruuning a rails application as windows service like
 first i created an empty service using instsrv.exe and srvany.exe with
named smruti_exp ,then i edit in regedit to make this empty service work

  This is  how running smruti_exp  as  service
  [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\smruti_exp\Parameters]
  Application=ruby
  AppParameters=script\server -b 192.168.247.49 -p 3000
  AppDirectory=D:\work\Smruti1\src


am running mongrel to do all work,but i would like to run apache server
as front server ,so i made some chnges in http.conf files come with
Apache





LoadModule rewrite_module modules/mod_rewrite.so
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
LoadModule proxy_http_module modules/mod_proxy_http.so








NameVirtualHost *:80

#Proxy balancer section (create one for each ruby app cluster)
<Proxy balancer://src_cluster>
  BalancerMember http://src:3000
 # BalancerMember http://myapp:3011
</Proxy>

#Virtual host section (create one for each ruby app you need to publish)
<VirtualHost *:80>
  ServerName src
  DocumentRoot D:/work/Smruti1/src/public/

  <Directory D:/work/Smruti1/src/public/ >
      Options Indexes FollowSymLinks MultiViews
      AllowOverride All
      Order allow,deny
      allow from all
  </Directory>

  #log files
  ErrorLog /var/log/apache2/src_error.log
  # Possible values include: debug, info, notice, warn, error, crit,
  # alert, emerg.
  LogLevel warn
  CustomLog /var/log/apache2/src_access.log combined

  #Rewrite stuff
   RewriteEngine On

  # Check for maintenance file and redirect all requests
  RewriteCond %{DOCUMENT_ROOT}/system/maintenance.html -f
  RewriteCond %{SCRIPT_FILENAME} !maintenance.html
  RewriteRule ^.*$ /system/maintenance.html [L]

  # Rewrite index to check for static
  RewriteRule ^/$ /index.html [QSA]

  # Rewrite to check for Rails cached page
  RewriteRule ^([^.]+)$ $1.html [QSA]

  # Redirect all non-static requests to cluster
  RewriteCond %{DOCUMENT_ROOT}/%{REQUEST_FILENAME} !-f
  RewriteRule ^/(.*)$ balancer://src_cluster%{REQUEST_URI} [P,QSA,L]
</VirtualHost>

these are the changes i made and in host file
i added
192.168.247.49 src

and try to access my application like http://src
but not working what is the problem
-- 
Posted via http://www.ruby-forum.com/.
_______________________________________________
Mongrel-users mailing list
Mongrel-users@rubyforge.org
http://rubyforge.org/mailman/listinfo/mongrel-users

Reply via email to