分享

window Nginx 搭建本地图片服务器

 魏正钦的图书馆 2020-06-05

worker_processes  1;

events {

    worker_connections  1024;

}

http {

    include       mime.types;

    default_type  application/octet-stream;

    sendfile        on;

    keepalive_timeout  65;

    fastcgi_intercept_errors on;

    upstream testxx {    

        server  172.16.17.38:8080;  #跳三下

        server  172.16.17.38:9090;  #跳三下

    }

    server {

        listen       8081;

        server_name  localhost;

        location / {

            proxy_pass http://testxx;

        }

        location ~ /SharedImageServer/(headpic|contentpic)/.*\.(gif|jpg|jpeg|png)$ {

           root  D:\images;

   autoindex on;

        }

        error_page   500 502 503 504  /50x.html;

        location = /50x.html {

            root   html;

        }

    }

}

    本站是提供个人知识管理的网络存储空间,所有内容均由用户发布,不代表本站观点。请注意甄别内容中的联系方式、诱导购买等信息,谨防诈骗。如发现有害或侵权内容,请点击一键举报。
    转藏 分享 献花(0

    0条评论

    发表

    请遵守用户 评论公约

    类似文章 更多