nginx常用

Nginx  

nginx -c /etc/nginx/nginx.conf 启动

Nginx -s stop 停止

killall -9 nginx 

netstat -ltunp 查看进程

nginx -s reload 重启

 

cp -r 路径 指定路径

scp -r -p22222 /本地 root@1.0.0.0:/ 

 

转发 

     location = /passport/queryMobileByUserCode {

               proxy_pass http://;

     }

 

 

本地

/usr/local/nginx/conf

Chmod 777 *

 

server {

    listen       80;

    server_name  localhost;

    access_log  logs/access.log;

    error_log   logs/error.log;

 

 location / {

   root /data/webserver/www/;

   index index.html;

   }

}

posted @ 2018-05-23 17:34  -小白白白  阅读(109)  评论(0编辑  收藏  举报