mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
Allow app config override for encryptWithRootEncryptionKey
This commit is contained in:
@@ -250,8 +250,11 @@ const cryptographyFactory = () => {
|
||||
};
|
||||
};
|
||||
|
||||
const encryptWithRootEncryptionKey = (data: string) => {
|
||||
const appCfg = getConfig();
|
||||
const encryptWithRootEncryptionKey = (
|
||||
data: string,
|
||||
appCfgOverride?: Pick<TEnvConfig, "ROOT_ENCRYPTION_KEY" | "ENCRYPTION_KEY">
|
||||
) => {
|
||||
const appCfg = appCfgOverride || getConfig();
|
||||
const rootEncryptionKey = appCfg.ROOT_ENCRYPTION_KEY;
|
||||
const encryptionKey = appCfg.ENCRYPTION_KEY;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user