Hi everybody,
I just suscribe to the list because I have a problem using mongrel and
mongrel_cluster... I setup a server (debian unstable wich provide apache
2.2.3 as a pakage) but I have an error when I try to access my application :
ERROR 403 : Forbidden, You don't have permission to access / on this
server.
When I check apache's logs I found that :
[warn] proxy: No protocol handler was valid for the URL /. If you are using
a DSO version of mod_proxy, make sure the proxy submodules are included in
the configuration using LoadModule.
I googled this error and I found that I have to load 3 differents modules,
so I typed :
a2enmod proxy
a2enmod proxy_http
a2enmod proxy_balancer
each time I get this return : This module is already enabled!
So I have no idea to what can i do ...
This is my config :
-----------------------
cat /etc/apache2/mods-enabled/proxy.conf
<IfModule mod_proxy.c>
#turning ProxyRequests on and allowing proxying from all may allow
#spammers to use your proxy to send email.
ProxyRequests Off
<Proxy *>
AddDefaultCharset off
Order deny,allow
Allow from all
#Allow from .example.com
</Proxy>
# Enable/disable the handling of HTTP/1.1 "Via:" headers.
# ("Full" adds the server version; "Block" removes all outgoing Via:
headers)
# Set to one of: Off | On | Full | Block
ProxyVia On
</IfModule>
-----------------------
cat /etc/apache2/sites-enabled/demo.mysite.com
<VirtualHost *:80>
ServerName demo.mysite.com
DocumentRoot /var/rails/demo.mysite.com/current/public
<Directory "/var/rails/demo.mysite.com/current/public">
Options FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<Proxy balancer://mongrel_cluster>
BalancerMember <http://127.0.0.1:8000/>
BalancerMember <http://127.0.0.1:8001/>
BalancerMember <http://127.0.0.1:8002/>
</Proxy>
RewriteEngine On
# Make sure people go to demo.mysite.com, not myapp.com
#RewriteCond %{HTTP_HOST} ^myapp.com$ [NC]
#RewriteRule ^(.*)$ http://www.myapp.com$1 [R=301,L]
# Yes, I've read no-www.com, but my site already has much Google-Fu on
# www.blah.com. Feel free to comment this out.
# Uncomment for rewrite debugging
#RewriteLog logs/myapp_rewrite_log
#RewriteLogLevel 9
# 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://mongrel_cluster%{REQUEST_URI} [P,QSA,L]
# Deflate
AddOutputFilterByType DEFLATE text/html text/plain text/xml
application/xml application/xhtml+xml text/javascript text/css
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4.0[678] no-gzip
BrowserMatch \bMSIE !no-gzip !gzip-only-text/html
# Uncomment for deflate debugging
#DeflateFilterNote Input input_info
#DeflateFilterNote Output output_info
#DeflateFilterNote Ratio ratio_info
#LogFormat '"%r" %{output_info}n/%{input_info}n (%{ratio_info}n%%)'
deflate
#CustomLog logs/myapp_deflate_log deflate
ErrorLog /var/log/apache2/demo.mysite.com_errors_log
CustomLog /var/log/apache2/demo.mysite.com_log combined
</VirtualHost>
(Configuration comes principaly from
http://blog.codahale.com/2006/06/19/time-for-a-grown-up-server-rails-mongrel-apache-capistrano-and-you/
)
I need some help, thanks.
(Hope you understand my english... I'm french)
_______________________________________________
Mongrel-users mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/mongrel-users