feat(gatekeeper): add per workspace feature flags (#5303)

* feat(gatekeeper): add per workspace feature flags

* feat(workspaces): add admin api for granting and removing access to
workspace features

* fix(workspaces): use the correct constant name

* fix(workspaces): more test type fixes

* fix(shared): fix tests and types

* fix(workspaces): properly use exhaustive switch statement

* fix(workspaces): add new workspace plan feature to switch

* fix(workspaces): use regular integer, its fine for now...

* fix(workspaces): feature flag retention post checkout

* fix(gatekeeper): fix upsert plan tests
This commit is contained in:
Gergő Jedlicska
2025-08-26 10:23:02 +01:00
committed by GitHub
parent ae3086f681
commit 6982023dca
31 changed files with 616 additions and 386 deletions
@@ -0,0 +1,13 @@
import { type Knex } from 'knex'
export async function up(knex: Knex): Promise<void> {
await knex.schema.alterTable('workspace_plans', (table) => {
table.integer('featureFlags').notNullable().defaultTo(0)
})
}
export async function down(knex: Knex): Promise<void> {
await knex.schema.alterTable('workspace_plans', (table) => {
table.dropColumn('featureFlags')
})
}