Documentation ¶
Index ¶
- func CheckAll(db *gorm.DB)
- type Check
- func (c *Check) Check(db *gorm.DB)
- func (c Check) GetGraphQLData() (*GraphQLCheckData, error)
- func (c Check) GetHttpData() (*HttpCheckData, error)
- func (c Check) GetIcmpData() (*IcmpCheckData, error)
- func (c Check) GetTcpData() (*TcpCheckData, error)
- func (c Check) GetTlsData() (*TlsCheckData, error)
- func (Check) TableName() string
- type CheckExecution
- type GraphQLCheckData
- type HttpCheckData
- type HttpCheckDataAuth
- type HttpCheckDataAuthOIDC
- type IcmpCheckData
- type Namespace
- type PageCheck
- type Status
- type StatusPage
- type StatusPageData
- type TcpCheckData
- type TlsCheckData
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Check ¶
type Check struct { ID string `gorm:"primaryKey"` Name string `gorm:"uniqueIndex:checkname;index;not null"` NamespaceID string `gorm:"uniqueIndex:checkname;index;not null"` Namespace Namespace `gorm:"foreignKey:NamespaceID"` Type check.Type Data datatypes.JSON Frecuency string Status Status ErrorMsg string Uptime24h float64 Uptime7d float64 Uptime30d float64 Message string LatestCheck time.Time CreatedAt time.Time UpdatedAt time.Time DeletedAt gorm.DeletedAt `gorm:"index"` LastFailureNotified *time.Time LastCertificateNotified *time.Time LastWarningNotified *time.Time FailureCount int WarningCount int StatusPages []PageCheck `gorm:"foreignKey:CheckID"` Executions []CheckExecution }
func (Check) GetGraphQLData ¶
func (c Check) GetGraphQLData() (*GraphQLCheckData, error)
func (Check) GetHttpData ¶
func (c Check) GetHttpData() (*HttpCheckData, error)
func (Check) GetIcmpData ¶
func (c Check) GetIcmpData() (*IcmpCheckData, error)
func (Check) GetTcpData ¶
func (c Check) GetTcpData() (*TcpCheckData, error)
func (Check) GetTlsData ¶
func (c Check) GetTlsData() (*TlsCheckData, error)
type CheckExecution ¶
type CheckExecution struct { ID string `gorm:"primaryKey"` Status Status CreatedAt time.Time UpdatedAt time.Time ErrorMsg string Message string Stats datatypes.JSON CheckID string Check Check `gorm:"foreignKey:CheckID"` }
func (CheckExecution) GetStats ¶
func (e CheckExecution) GetStats() (map[string]interface{}, error)
func (CheckExecution) TableName ¶
func (CheckExecution) TableName() string
type GraphQLCheckData ¶
type GraphQLCheckData struct { Query string `json:"query"` Variables map[string]interface{} `json:"variables"` Url string `json:"url"` CertificateExpirationDelta string `json:"certificateExpirationDelta"` Auth *HttpCheckDataAuth `json:"auth"` }
type HttpCheckData ¶
type HttpCheckData struct { Url string `json:"url"` StatusCode int `json:"status_code"` CertificateExpirationDelta string `json:"certificateExpirationDelta"` Auth *HttpCheckDataAuth `json:"auth"` }
type HttpCheckDataAuth ¶
type HttpCheckDataAuth struct {
OIDC *HttpCheckDataAuthOIDC `json:"oidc"`
}
type HttpCheckDataAuthOIDC ¶
type IcmpCheckData ¶
type IcmpCheckData struct {
Address string `json:"address"`
}
type PageCheck ¶
type PageCheck struct { CheckID string `gorm:"primaryKey"` Check Check `gorm:"foreignKey:CheckID"` StatusPageID string `gorm:"primaryKey;uniqueIndex:pagecheckorder;index;not null"` StatusPage StatusPage `gorm:"foreignKey:StatusPageID"` Order int `gorm:"uniqueIndex:pagecheckorder;index"` CreatedAt time.Time }
type StatusPage ¶
type StatusPage struct { ID string `gorm:"primary_key"` Title string Name string `gorm:"uniqueIndex:statusslugns;index;not null"` Slug string `gorm:"uniqueIndex"` NamespaceID string `gorm:"uniqueIndex:statusslugns;index;not null"` Namespace Namespace `gorm:"foreignKey:NamespaceID"` Data datatypes.JSON Checks []PageCheck `gorm:"foreignKey:StatusPageID"` CreatedAt time.Time UpdatedAt time.Time DeletedAt gorm.DeletedAt `gorm:"index"` }
func (StatusPage) GetData ¶
func (s StatusPage) GetData() (*StatusPageData, error)
func (StatusPage) TableName ¶
func (StatusPage) TableName() string
type StatusPageData ¶
type StatusPageData struct {
OrderChecks []string
}
type TcpCheckData ¶
type TcpCheckData struct {
Address string `json:"address"`
}
type TlsCheckData ¶
Click to show internal directories.
Click to hide internal directories.