Skip to content

Commit

Permalink
be: change influx secret key name (#68)
Browse files Browse the repository at this point in the history
* be: change influx secret key name

* logging stuff
  • Loading branch information
mat1asm authored Apr 2, 2024
1 parent f99c819 commit d041392
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion backend/src/utils/persistence.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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 () => {
Expand Down
2 changes: 1 addition & 1 deletion backend/src/utils/secrets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export async function getInfluxToken(): Promise<string> {
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
Expand Down

0 comments on commit d041392

Please sign in to comment.