chore: Move API source code to API folder.
This commit is contained in:
parent
8015b0af74
commit
d3a664fea4
59 changed files with 43 additions and 38 deletions
53
api/prisma/schema.prisma
Normal file
53
api/prisma/schema.prisma
Normal file
|
@ -0,0 +1,53 @@
|
|||
// This is your Prisma schema file,
|
||||
// learn more about it in the docs: https://pris.ly/d/prisma-schema
|
||||
|
||||
generator client {
|
||||
provider = "prisma-client-js"
|
||||
}
|
||||
|
||||
datasource db {
|
||||
provider = "postgresql"
|
||||
url = env("DATABASE_URL")
|
||||
}
|
||||
|
||||
model DesinationProvider {
|
||||
id Int @id @default(autoincrement())
|
||||
|
||||
name String
|
||||
description String?
|
||||
backend String
|
||||
connectionDetails String
|
||||
}
|
||||
|
||||
model ForwardRule {
|
||||
id Int @id @default(autoincrement())
|
||||
|
||||
name String
|
||||
description String?
|
||||
protocol String
|
||||
sourceIP String
|
||||
sourcePort Int
|
||||
destPort Int
|
||||
destProviderID Int
|
||||
enabled Boolean
|
||||
}
|
||||
|
||||
model Permission {
|
||||
id Int @id @default(autoincrement())
|
||||
|
||||
permission String
|
||||
has Boolean
|
||||
user User @relation(fields: [userID], references: [id])
|
||||
userID Int
|
||||
}
|
||||
|
||||
model User {
|
||||
id Int @id @default(autoincrement())
|
||||
|
||||
email String @unique
|
||||
name String
|
||||
password String // Will be hashed using bcrypt
|
||||
rootToken String?
|
||||
isRootServiceAccount Boolean?
|
||||
permissions Permission[]
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue