2022-10-28 09:04:57 +00:00
|
|
|
package model
|
|
|
|
|
2022-11-11 09:41:39 +00:00
|
|
|
import "time"
|
|
|
|
|
2022-12-13 09:20:13 +00:00
|
|
|
type WebsiteSSL struct {
|
2022-10-28 09:04:57 +00:00
|
|
|
BaseModel
|
2023-01-04 03:44:43 +00:00
|
|
|
PrimaryDomain string `gorm:"type:varchar(256);not null" json:"primaryDomain"`
|
|
|
|
PrivateKey string `gorm:"type:longtext;not null" json:"privateKey"`
|
|
|
|
Pem string `gorm:"type:longtext;not null" json:"pem"`
|
|
|
|
Domains string `gorm:"type:varchar(256);not null" json:"domains"`
|
|
|
|
CertURL string `gorm:"type:varchar(256);not null" json:"certURL"`
|
|
|
|
Type string `gorm:"type:varchar(64);not null" json:"type"`
|
|
|
|
Provider string `gorm:"type:varchar(64);not null" json:"provider"`
|
|
|
|
Organization string `gorm:"type:varchar(64);not null" json:"organization"`
|
|
|
|
DnsAccountID uint `gorm:"type:integer;not null" json:"dnsAccountId"`
|
|
|
|
AcmeAccountID uint `gorm:"type:integer;not null" json:"acmeAccountId"`
|
|
|
|
AutoRenew bool `gorm:"type:varchar(64);not null" json:"autoRenew"`
|
|
|
|
ExpireDate time.Time `json:"expireDate"`
|
|
|
|
StartDate time.Time `json:"startDate"`
|
|
|
|
|
2023-02-27 09:22:14 +00:00
|
|
|
AcmeAccount WebsiteAcmeAccount `json:"acmeAccount" gorm:"-:migration"`
|
|
|
|
Websites []Website `json:"websites" gorm:"-:migration"`
|
2022-11-11 09:41:39 +00:00
|
|
|
}
|
|
|
|
|
2022-12-13 09:20:13 +00:00
|
|
|
func (w WebsiteSSL) TableName() string {
|
2022-11-11 09:41:39 +00:00
|
|
|
return "website_ssls"
|
2022-10-28 09:04:57 +00:00
|
|
|
}
|