feat: resolved migration failing due to json

This commit is contained in:
=
2025-02-10 15:46:38 +05:30
parent cbbafcfa42
commit 1e4164e1c2
3 changed files with 12 additions and 3 deletions
@@ -137,7 +137,12 @@ const reencryptIdentityK8sAuth = async (knex: Knex) => {
plainText: Buffer.from(decryptedCertificate)
}).cipherTextBlob;
return { ...el, encryptedKubernetesCaCertificate, encryptedKubernetesTokenReviewerJwt };
return {
...el,
accessTokenTrustedIps: JSON.stringify(el.accessTokenTrustedIps),
encryptedKubernetesCaCertificate,
encryptedKubernetesTokenReviewerJwt
};
}
)
);
@@ -96,7 +96,11 @@ const reencryptIdentityOidcAuth = async (knex: Knex) => {
plainText: Buffer.from(decryptedCertificate)
}).cipherTextBlob;
return { ...el, encryptedCaCertificate };
return {
...el,
accessTokenTrustedIps: JSON.stringify(el.accessTokenTrustedIps),
encryptedCaCertificate
};
}
)
);
@@ -12,7 +12,7 @@ import {
validateOidcBoundClaimsField
} from "@app/services/identity-oidc-auth/identity-oidc-auth-validators";
const IdentityOidcAuthResponseSchema = IdentityOidcAuthsSchema.omit({
const IdentityOidcAuthResponseSchema = IdentityOidcAuthsSchema.pick({
id: true,
accessTokenTTL: true,
accessTokenMaxTTL: true,