nginx 反向代理到 apache
server {
listen 80;
server_name app.haeee.com;
index index.html index.htm index.php;
root /alidata/www/movie-app;
error_page 404 500 502 503 504 http://app.haeee.com;
location ~ .*\.(php|php5)?$
{
#fastcgi_pass unix:/tmp/php-cgi.sock;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
include fastcgi.conf;
}
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
expires 30d;
}
location ~ .*\.(js|css)?$
{
expires 1h;
}
#伪静态规则
#include /alidata/server/nginx/conf/rewrite/phpwind.conf;
access_log /alidata/log/nginx/access/movie-app.log;
}
nginx 反向代理到 tomcat
server {
listen 80;
server_name hulasou.com www.hulasou.com;
index index.html index.htm index.jsp;
#location ~ .*\.(jsp)?$
location /{
index index.jsp;
proxy_pass http://localhost:8181;
}
#伪静态规则
include /alidata/server/nginx/conf/rewrite/uuxiaohua.conf;
access_log /alidata/log/nginx/access/uuxiaohua.log;
}