Add tags support for secrets

This commit is contained in:
Maidul Islam
2023-02-05 12:54:42 -08:00
parent 8ae43cdcf6
commit 9f9273bb02
9 changed files with 221 additions and 26 deletions
+7 -1
View File
@@ -21,6 +21,7 @@ export interface ISecretVersion {
secretValueIV: string;
secretValueTag: string;
secretValueHash: string;
tags?: string[];
}
const secretVersionSchema = new Schema<ISecretVersion>(
@@ -88,7 +89,12 @@ const secretVersionSchema = new Schema<ISecretVersion>(
},
secretValueHash: {
type: String
}
},
tags: {
ref: 'Tag',
type: [Schema.Types.ObjectId],
default: []
},
},
{
timestamps: true