summaryrefslogtreecommitdiff
path: root/worker
diff options
context:
space:
mode:
authorElizabeth Hunt <me@liz.coffee>2025-07-26 16:27:24 -0700
committerElizabeth Hunt <me@liz.coffee>2025-07-26 16:51:38 -0700
commitdf1a7eec824d9e9d99c58b1f7792c8f384955273 (patch)
tree777293cac122ec41fc00e7df93ae30dfe85ebc13 /worker
parentf0898a3c19fafc5784385371beac6304b36f8f79 (diff)
downloadci-df1a7eec824d9e9d99c58b1f7792c8f384955273.tar.gz
ci-df1a7eec824d9e9d99c58b1f7792c8f384955273.zip
Adds better secret log liens
Diffstat (limited to 'worker')
-rw-r--r--worker/secret.ts14
1 files changed, 10 insertions, 4 deletions
diff --git a/worker/secret.ts b/worker/secret.ts
index 241823d..30316bd 100644
--- a/worker/secret.ts
+++ b/worker/secret.ts
@@ -47,9 +47,12 @@ export class Bitwarden implements IVault<TClient, TKey, TItemId> {
.flatMap((tConfig) => tConfig.move(`bw config server ${tConfig.get().server}`).map(getStdout))
.map(async (tEitherWithConfig) => {
const eitherWithConfig = await tEitherWithConfig.get();
- tEitherWithConfig.trace.trace('logging in~ ^.^');
return eitherWithConfig.flatMapAsync((_) =>
- tEitherWithConfig.move('bw login --apikey --quiet').map(getStdout).get(),
+ tEitherWithConfig
+ .peek((t) => t.trace.trace('logging in~ ^.^'))
+ .move('bw login --apikey --quiet')
+ .map(getStdout)
+ .get(),
);
})
.peek(TraceUtil.promiseify(TraceUtil.traceResultingEither(Bitwarden.loginMetric)));
@@ -57,9 +60,12 @@ export class Bitwarden implements IVault<TClient, TKey, TItemId> {
.flatMap(TraceUtil.withMetricTrace(Bitwarden.unlockVaultMetric))
.map(async (tEitherWithAuthd) => {
const eitherWithAuthd = await tEitherWithAuthd.get();
- tEitherWithAuthd.trace.trace('unlocking the secret vault~ (◕ᴗ◕✿)');
return eitherWithAuthd.flatMapAsync((_) =>
- tEitherWithAuthd.move('bw unlock --passwordenv BW_PASSWORD --raw').map(getStdout).get(),
+ tEitherWithAuthd
+ .peek((t) => t.trace.trace('unlocking the secret vault~ (◕ᴗ◕✿)'))
+ .move('bw unlock --passwordenv BW_PASSWORD --raw')
+ .map(getStdout)
+ .get(),
);
})
.peek(TraceUtil.promiseify(TraceUtil.traceResultingEither(Bitwarden.unlockVaultMetric)));