From 525e64d01b89d4e47847aba609570eee464841de Mon Sep 17 00:00:00 2001 From: matias martinez Date: Mon, 1 Apr 2024 23:11:50 -0300 Subject: [PATCH 1/2] be: change influx secret key name --- backend/src/utils/secrets.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/src/utils/secrets.ts b/backend/src/utils/secrets.ts index f148c0d1..b39c0cef 100644 --- a/backend/src/utils/secrets.ts +++ b/backend/src/utils/secrets.ts @@ -38,7 +38,7 @@ export async function getInfluxToken(): Promise { console.log('Using influx token from config') key = config.secrets.influx.key()! } else { - key = await getSecretKey(config.secrets.influx.secretName, 'key') + key = await getSecretKey(config.secrets.influx.secretName, 'idb-token') } return key From 6925c0c3d65b10b26c622974488b6478b3860c16 Mon Sep 17 00:00:00 2001 From: matias martinez Date: Mon, 1 Apr 2024 23:40:19 -0300 Subject: [PATCH 2/2] logging stuff --- backend/src/utils/persistence.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/backend/src/utils/persistence.ts b/backend/src/utils/persistence.ts index 92aaeb83..57b42a1c 100644 --- a/backend/src/utils/persistence.ts +++ b/backend/src/utils/persistence.ts @@ -117,10 +117,14 @@ function mapIdentity(claimSignature: ClaimSignature) { async function initInfluxWriter() { const token = await getInfluxToken() + console.log('Influx URL: ' + config.influx.url()) + console.log('Influx ORG: ' + config.influx.org()) + console.log('Influx BUCKET: ' + config.influx.bucket()) + return new InfluxDB({ url: config.influx.url(), token - }).getWriteApi(config.influx.org(), config.influx.bucket(), 'ms') + }).getWriteApi(config.influx.org(), config.influx.bucket()) } process.on('SIGTERM', async () => {