feat: self-hosted provider
This commit is contained in:
9
.vscode/settings.json
vendored
9
.vscode/settings.json
vendored
@@ -3,5 +3,12 @@
|
|||||||
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
||||||
"editor.formatOnSave": true,
|
"editor.formatOnSave": true,
|
||||||
"editor.formatOnSaveMode": "file",
|
"editor.formatOnSaveMode": "file",
|
||||||
"cSpell.words": ["blocksuite", "datacenter", "livedemo", "pnpm", "testid"]
|
"cSpell.words": [
|
||||||
|
"blocksuite",
|
||||||
|
"datacenter",
|
||||||
|
"livedemo",
|
||||||
|
"pnpm",
|
||||||
|
"selfhosted",
|
||||||
|
"testid"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -46,6 +46,10 @@ const nextConfig = {
|
|||||||
source: '/api/:path*',
|
source: '/api/:path*',
|
||||||
destination: destinationAC,
|
destination: destinationAC,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
source: '/collaboration/:path*',
|
||||||
|
destination: 'http://localhost:3000/collaboration/:path*',
|
||||||
|
},
|
||||||
];
|
];
|
||||||
} else {
|
} else {
|
||||||
let destinationStandard = 'http://100.77.180.48:11001/api/:path*';
|
let destinationStandard = 'http://100.77.180.48:11001/api/:path*';
|
||||||
@@ -58,6 +62,10 @@ const nextConfig = {
|
|||||||
source: '/api/:path*',
|
source: '/api/:path*',
|
||||||
destination: destinationStandard,
|
destination: destinationStandard,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
source: '/collaboration/:path*',
|
||||||
|
destination: 'http://localhost:3000/collaboration/:path*',
|
||||||
|
},
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ const DynamicBlocksuite = ({
|
|||||||
const openWorkspace: LoadWorkspaceHandler = async (workspaceId: string) => {
|
const openWorkspace: LoadWorkspaceHandler = async (workspaceId: string) => {
|
||||||
if (workspaceId) {
|
if (workspaceId) {
|
||||||
const dc = await getDataCenter();
|
const dc = await getDataCenter();
|
||||||
return dc.load(workspaceId, { providerId: 'affine' });
|
return dc.load(workspaceId, { providerId: 'selfhosted' });
|
||||||
} else {
|
} else {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user