mirror of
https://github.com/hyperdxio/hyperdx
synced 2026-04-21 13:37:15 +00:00
add aws4 to api to allow mongo aws auth (#1345)
This commit is contained in:
parent
337be9a2d1
commit
cac4d3ddca
4 changed files with 28 additions and 0 deletions
5
.changeset/flat-maps-flow.md
Normal file
5
.changeset/flat-maps-flow.md
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
"@hyperdx/api": patch
|
||||
---
|
||||
|
||||
Allow connecting to Mongo with AWS Auth
|
||||
|
|
@ -18,6 +18,7 @@
|
|||
"@slack/webhook": "^6.1.0",
|
||||
"@types/node": "^22.15.18",
|
||||
"ai": "5.0.59",
|
||||
"aws4": "^1.13.2",
|
||||
"chrono-node": "^2.9.0",
|
||||
"compression": "^1.7.4",
|
||||
"connect-mongo": "^4.6.0",
|
||||
|
|
@ -50,6 +51,7 @@
|
|||
"zod-express-middleware": "^1.4.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/aws4": "^1",
|
||||
"@types/compression": "^1.7.3",
|
||||
"@types/cors": "^2.8.14",
|
||||
"@types/express": "^4.17.13",
|
||||
|
|
|
|||
|
|
@ -35,6 +35,9 @@ mongoose.connection.on('reconnectFailed', () => {
|
|||
});
|
||||
|
||||
export const connectDB = async () => {
|
||||
// breadcrumbs for future greppers: aws4 is included as a dependency of the api so that
|
||||
// users can use AWS auth in their mongo connection string here, e.g.
|
||||
// mongodb+srv://blahblah...mongodb.net/hyperdx?authSource=%24external&authMechanism=MONGODB-AWS
|
||||
if (config.MONGO_URI == null) {
|
||||
throw new Error('MONGO_URI is not set');
|
||||
}
|
||||
|
|
|
|||
18
yarn.lock
18
yarn.lock
|
|
@ -4501,6 +4501,7 @@ __metadata:
|
|||
"@opentelemetry/host-metrics": "npm:^0.35.5"
|
||||
"@opentelemetry/sdk-metrics": "npm:^1.30.1"
|
||||
"@slack/webhook": "npm:^6.1.0"
|
||||
"@types/aws4": "npm:^1"
|
||||
"@types/compression": "npm:^1.7.3"
|
||||
"@types/cors": "npm:^2.8.14"
|
||||
"@types/express": "npm:^4.17.13"
|
||||
|
|
@ -4516,6 +4517,7 @@ __metadata:
|
|||
"@types/swagger-jsdoc": "npm:^6"
|
||||
"@types/uuid": "npm:^8.3.4"
|
||||
ai: "npm:5.0.59"
|
||||
aws4: "npm:^1.13.2"
|
||||
chrono-node: "npm:^2.9.0"
|
||||
compression: "npm:^1.7.4"
|
||||
connect-mongo: "npm:^4.6.0"
|
||||
|
|
@ -9902,6 +9904,15 @@ __metadata:
|
|||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@types/aws4@npm:^1":
|
||||
version: 1.11.6
|
||||
resolution: "@types/aws4@npm:1.11.6"
|
||||
dependencies:
|
||||
"@types/node": "npm:*"
|
||||
checksum: 10c0/abb84d0dad0b791124389b1bfd2c4c2813077af162cac128f1eb0793f0d4fe3084aa1168f62b41e39f80730aa45b95a9a0034f85c254bebf2194721fe02bc9ad
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"@types/babel__core@npm:^7.1.14":
|
||||
version: 7.20.0
|
||||
resolution: "@types/babel__core@npm:7.20.0"
|
||||
|
|
@ -12660,6 +12671,13 @@ __metadata:
|
|||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"aws4@npm:^1.13.2":
|
||||
version: 1.13.2
|
||||
resolution: "aws4@npm:1.13.2"
|
||||
checksum: 10c0/c993d0d186d699f685d73113733695d648ec7d4b301aba2e2a559d0cd9c1c902308cc52f4095e1396b23fddbc35113644e7f0a6a32753636306e41e3ed6f1e79
|
||||
languageName: node
|
||||
linkType: hard
|
||||
|
||||
"axe-core@npm:=4.7.0":
|
||||
version: 4.7.0
|
||||
resolution: "axe-core@npm:4.7.0"
|
||||
|
|
|
|||
Loading…
Reference in a new issue