Skip to content

默认后端api端口与前端vite config不一致 #4

@AlabasterStone

Description

@AlabasterStone

默认后端api是http://localhost:8000/api/v1
vite.config.ts配置的代理:

    proxy: {
      '/api': {
        target: 'http://localhost:8211',
        changeOrigin: true,
      },
      '/outputs': {
        target: 'http://localhost:8211',
        changeOrigin: true,
      },
    }

然后INTEGRATION_GUIDE.md里又写:确保后端服务运行在 http://localhost:8210

导致出现:

[vite] http proxy error: /api/v1/kb/notebooks
AggregateError [ECONNREFUSED]: 
    at internalConnectMultiple (node:net:1134:18)
    at afterConnectMultiple (node:net:1715:7)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions