Files
jerapah-flow/packages/server/migrations/20260830000006_secrets.js
T
nsrb 3f0774813d refactor(config): remove legacy config reference handling and streamline YAML management
- Deleted legacy config reference handling functions and related migration scripts to simplify the codebase.
- Updated documentation to reflect the removal of legacy YAML paths and configurations.
- Adjusted existing YAML management processes to ensure compatibility with the new mustache-style syntax.
- Removed tests related to legacy config references, focusing on current functionality and ensuring clarity in the testing suite.
2026-08-30 15:37:58 +07:00

28 lines
690 B
JavaScript

/**
* @param {import("knex").Knex} knex
*/
export async function up(knex) {
await knex.schema.createTable("secrets", (t) => {
t.text("id").primary();
t.text("owner").notNullable();
t.text("name").notNullable();
t.text("ciphertext").notNullable();
t.text("iv").notNullable();
t.text("auth_tag").notNullable();
t.text("created_at").notNullable();
t.text("updated_at").notNullable();
t.unique(["owner", "name"]);
});
await knex.schema.raw(
"CREATE INDEX secrets_owner_name_idx ON secrets (owner, name)",
);
}
/**
* @param {import("knex").Knex} knex
*/
export async function down(knex) {
await knex.schema.dropTableIfExists("secrets");
}