Skip to content

Instantly share code, notes, and snippets.

@zhangchunlin
Created October 17, 2019 01:34
Show Gist options
  • Save zhangchunlin/32ad84fa3b794728c958f7579f427251 to your computer and use it in GitHub Desktop.
Save zhangchunlin/32ad84fa3b794728c958f7579f427251 to your computer and use it in GitHub Desktop.

Revisions

  1. zhangchunlin created this gist Oct 17, 2019.
    31 changes: 31 additions & 0 deletions openresty.conf
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,31 @@
    worker_processes 1;

    error_log logs/error.log;

    events {
    worker_connections 1024;
    }

    http {
    server {
    listen 6699;
    location @uliweb{
    proxy_pass http://localhost:8000;
    }
    location @vue{
    proxy_pass http://localhost:8080;
    }
    location / {
    default_type text/html;
    content_by_lua_block {
    ngx.exec("@vue")
    }
    }
    location /backend {
    default_type text/html;
    content_by_lua_block {
    ngx.exec("@uliweb")
    }
    }
    }
    }