init from gitlab
This commit is contained in:
22
internal/models/auth.go
Normal file
22
internal/models/auth.go
Normal file
@@ -0,0 +1,22 @@
|
||||
package models
|
||||
|
||||
import "gorm.io/gorm"
|
||||
|
||||
type User struct {
|
||||
gorm.Model
|
||||
Name string `gorm:"unique"`
|
||||
Source string
|
||||
SSHKeys []SSHKey
|
||||
|
||||
PasswordHash []byte
|
||||
TotpEnabled bool
|
||||
TotpSecret string
|
||||
RecoveryCode string
|
||||
}
|
||||
|
||||
type SSHKey struct {
|
||||
gorm.Model
|
||||
UserID uint
|
||||
GithubID int64 `gorm:"unique"`
|
||||
Key string
|
||||
}
|
||||
Reference in New Issue
Block a user