skywalking 9 自定义路径部署

2023-02-20  本文已影响0人  akka9
skywalking 9 的前端代码 skywalking-booster-ui-9.x  改这四个文件:
vue.config.js  module.exports 下面增加:  publicPath: './',  
src/graphql/fetch.ts  把后端接口地址由 /graphql 改为   /api/skywalking9/graphql
src/graphql/index.ts  把后端接口地址由 /graphql 改为   /api/skywalking9/graphql
src/router/index.ts   两处 createWebHistory  改为  createWebHashHistory

nginx 配置参考:
location /skywalking9 { alias /web/skywalking-booster-ui-9.2.0/dist/; try_files $uri $uri/ /index.html; }

location /api/skywalking9/graphql {
      proxy_set_header X-Real-IP $remote_addr;
      proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
      proxy_set_header Host $http_host;
      proxy_set_header X-NginX-Proxy true;
      proxy_pass http://oap-server:12800;
      proxy_redirect off;
}



上一篇下一篇

猜你喜欢

热点阅读