mirror of
https://github.com/mentos1386/zdravko.git
synced 2024-11-25 17:05:21 +00:00
41 lines
582 B
Go
41 lines
582 B
Go
package models
|
|
|
|
import (
|
|
"time"
|
|
|
|
"gorm.io/gorm"
|
|
)
|
|
|
|
type OAuth2State struct {
|
|
State string `gorm:"primary_key"`
|
|
Expiry time.Time
|
|
}
|
|
|
|
type Healthcheck struct {
|
|
gorm.Model
|
|
Name string `gorm:"unique"`
|
|
Status string // UP, DOWN
|
|
UptimePercentage float64
|
|
Schedule string
|
|
}
|
|
|
|
type HealthcheckHTTP struct {
|
|
gorm.Model
|
|
Healthcheck
|
|
URL string
|
|
Method string
|
|
}
|
|
|
|
type HealthcheckTCP struct {
|
|
gorm.Model
|
|
Healthcheck
|
|
Hostname string
|
|
Port int
|
|
}
|
|
|
|
type Cronjob struct {
|
|
gorm.Model
|
|
Name string `gorm:"unique"`
|
|
Schedule string
|
|
Buffer int
|
|
}
|