Skip to content

Commit

Permalink
feat(mongo): add env opt to enable webrtc (#959)
Browse files Browse the repository at this point in the history
  • Loading branch information
Thrimbda authored Jan 2, 2025
1 parent b6dd947 commit b647e02
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
3 changes: 3 additions & 0 deletions apps/mongodb-storage/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ export default (context: IExtensionContext) => {
TERMINAL_ID: {
type: 'string',
},
ENABLE_WEBRTC: {
type: 'string',
},
MONGO_URI: {
type: 'string',
description: `mongodb://[username:password@]host1[:port1][,...hostN[:portN]][/[defaultauthdb][?options]],参考 https://www.mongodb.com/docs/manual/reference/connection-string/`,
Expand Down
1 change: 1 addition & 0 deletions apps/mongodb-storage/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ const HOST_URL = process.env.HOST_URL || process.env.HV_URL!;
const TERMINAL_ID = process.env.TERMINAL_ID || `MongoDB/${UUID()}`;
const terminal = new Terminal(HOST_URL, {
terminal_id: TERMINAL_ID,
enable_WebRTC: process.env.ENABLE_WEBRTC === 'true',
name: 'MongoDB Storage',
});

Expand Down
10 changes: 10 additions & 0 deletions common/changes/@yuants/app-mongodb-storage/2025-01-02-14-11.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"changes": [
{
"packageName": "@yuants/app-mongodb-storage",
"comment": "add env option to enable web rtc",
"type": "patch"
}
],
"packageName": "@yuants/app-mongodb-storage"
}

0 comments on commit b647e02

Please sign in to comment.