fix: one secrets temp dir per env building

This commit is contained in:
Nicolas Meienberger 2026-05-17 18:04:33 +02:00
parent 0fa4e05ba0
commit 7fd7d5a61c
No known key found for this signature in database

View file

@ -32,8 +32,10 @@ export const buildEnv = async (
};
let runtimeSecretsDir: string | undefined;
const getRuntimeSecretPath = async (filename: string) => {
runtimeSecretsDir = await createRuntimeSecretsDir();
env._RUNTIME_SECRETS_DIR = runtimeSecretsDir;
if (!runtimeSecretsDir) {
runtimeSecretsDir = await createRuntimeSecretsDir();
env._RUNTIME_SECRETS_DIR = runtimeSecretsDir;
}
return runtimeSecretPath(runtimeSecretsDir, filename);
};