mirror of
https://github.com/fosrl/pangolin.git
synced 2025-08-04 01:55:10 +02:00
Add table
This commit is contained in:
parent
3c7025a327
commit
befdc3a002
1 changed files with 10 additions and 0 deletions
|
@ -371,6 +371,16 @@ export const versionMigrations = sqliteTable("versionMigrations", {
|
|||
executedAt: integer("executedAt").notNull()
|
||||
});
|
||||
|
||||
export const badgerRules = sqliteTable("badgerRules", {
|
||||
ruleId: integer("ruleId").primaryKey({ autoIncrement: true }),
|
||||
resourceId: integer("resourceId")
|
||||
.notNull()
|
||||
.references(() => resources.resourceId, { onDelete: "cascade" }),
|
||||
action: text("action").notNull(), // ACCEPT, DROP
|
||||
match: text("match").notNull(), // CIDR, PATH
|
||||
value: text("value").notNull()
|
||||
});
|
||||
|
||||
export type Org = InferSelectModel<typeof orgs>;
|
||||
export type User = InferSelectModel<typeof users>;
|
||||
export type Site = InferSelectModel<typeof sites>;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue