Nginx配置反向代理

http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;
    upstream apachephp  {                       #配置访问组
        server 127.0.0.1:8080; #Apache    #配置代理服务器
        }
    server {
        listen       80;
        server_name  localhost;
        location / {
           ` proxy_pass  http://apachephp;  #配置访问组
            root   html;
            index  index.php index.html index.htm;
        }
    }
}

猜你喜欢

转载自blog.51cto.com/yht1990/2140644