[关闭]
@GivenCui 2017-07-07T19:11:35.000000Z 字数 766 阅读 794

nginx积累

nginx


参考链接

Nginx常用配置-简书
Nginx开发从入门到精通
openresty-菜鸟教程
openresty-HOME
openresty-最佳实践

ptest开发环境配置

  1. // openresty/site-enabled/devptest.hujiang.com.conf
  2. /*
  3. * gulp.js localhost:9000 =>
  4. * openresty/site-enabled/devptest.hujiang.com.conf http://127.0.0.1:9000/ ==> devptest.hujiang.com:80
  5. *
  6. /
  7. server {
  8. listen 80;
  9. server_name devptest.hujiang.com;
  10. access_log /usr/local/var/log/nginx/devptest.hujiang.com.access.log main;
  11. // location
  12. location ~ /\.ht {
  13. deny all;
  14. }
  15. location = /favicon.ico {
  16. log_not_found off;
  17. access_log off;
  18. }
  19. location /oral/ {
  20. alias /Users/Given/Working/ptest/oral/dist/;
  21. }
  22. location /dist/ {
  23. root /Users/Given/Working/ptest/dist/;
  24. }
  25. location /api/oral/ {
  26. proxy_set_header Host qaptest.hujiang.com;
  27. proxy_pass http://qaptest.hujiang.com/api/oral/;
  28. }
  29. location / {
  30. proxy_set_header Host $host;
  31. proxy_pass http://127.0.0.1:9000/;
  32. }
  33. }

添加新批注
在作者公开此批注前,只有你和作者可见。
回复批注