Nginx-ru mailing list archive (nginx-ru@sysoev.ru)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Здравствуйте!
- To: nginx-ru@xxxxxxxxx
- Subject: Здравствуйте!
- From: "server801" <nginx-forum@xxxxxxxx>
- Date: Fri, 18 Jun 2010 09:53:33 -0400
- Dkim-signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mickey.jlkhosting.com; s=x; h=Sender:From:Message-ID:Content-Transfer-Encoding:Content-Type:Subject:To:Date; bh=5aEqvmZe4MeFQhahco4eyyKcXtBQX+g3L20U2ovxoKM=; b=tORYzhDUAcZQX/Vx8kjcNK1PTjxPmBENKEBN2CwtsmdrUvJ+C0YPtS0+DP6EWaHwfhQ0pVHCox9FBwd8GR1qcYtZcBlZZIPMweaa/HcChMj0ZMd642VmJCVWbELyd8zE;
Есть CentOS 5.4 версия nginx 0.8.36, связка
nginx+php_fpm. Как сделать редирект при
обращении к http://site.com на http://www.site.com ?
Вот конфиг
[code]
server {
listen 80;
server_name site.com www.site.com;
location / {
root /var/www/html/site.com;
index home.php index.php;
include /etc/nginx/mime.types;
charset utf-8;
default_type application/octet-stream;
access_log /var/log/nginx/site_access_log main;
error_log /var/log/nginx/site_error_log;
keepalive_timeout 0;
server_tokens off;
#gzip on;
#gzip_buffers 5 6k;
#gzip_comp_level 7;
#gzip_proxied any;
#gzip_types text/plain text/css application/x-javascript
text/xml application/xml application/xml+rss text/javascri$
sendfile on;
proxy_buffering on;
#output_buffers 1 256k;
client_max_body_size 2000m;
tcp_nopush on;
tcp_nodelay on;
location ~ \.flv$ {
flv;
}
location ~ /\.ht {
deny all;
}
location ~ \.php$ {
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME
/var/www/html/mapkc.org$fastcgi_script_name;
include fastcgi_params;
}
[/code]
Если дублирую тему и где то решение уже
есть, не пинайте сильно, обыскал и
перерыл уже все
Posted at Nginx Forum: http://forum.nginx.org/read.php?21,99877,99877#msg-99877
_______________________________________________
nginx-ru mailing list
nginx-ru@xxxxxxxxx
http://nginx.org/mailman/listinfo/nginx-ru
|