1Panel/backend/app/dto/request/nginx.go

51 lines
1.5 KiB
Go
Raw Normal View History

2022-12-09 17:16:07 +08:00
package request
2022-12-13 18:54:46 +08:00
import "github.com/1Panel-dev/1Panel/backend/app/dto"
2022-12-09 17:16:07 +08:00
type NginxConfigFileUpdate struct {
Content string `json:"content" validate:"required"`
FilePath string `json:"filePath" validate:"required"`
Backup bool `json:"backup" validate:"required"`
}
2022-12-13 18:54:46 +08:00
type NginxScopeReq struct {
Scope dto.NginxKey `json:"scope" validate:"required"`
WebsiteID uint `json:"websiteId"`
}
type NginxConfigUpdate struct {
Scope dto.NginxKey `json:"scope"`
Operate string `json:"operate" validate:"required;oneof=add update delete"`
WebsiteID uint `json:"websiteId" validate:"required"`
Params interface{} `json:"params"`
}
2023-04-14 16:01:06 +08:00
type NginxRewriteReq struct {
WebsiteID uint `json:"websiteId" validate:"required"`
Name string `json:"name" validate:"required"`
}
type NginxRewriteUpdate struct {
WebsiteID uint `json:"websiteId" validate:"required"`
Name string `json:"name" validate:"required"`
Content string `json:"content" validate:"required"`
}
type NginxProxyUpdate struct {
WebsiteID uint `json:"websiteID" validate:"required"`
Content string `json:"content" validate:"required"`
Name string `json:"name" validate:"required"`
}
type NginxAuthUpdate struct {
WebsiteID uint `json:"websiteID" validate:"required"`
Operate string `json:"operate" validate:"required"`
Username string `json:"username" validate:"required"`
Password string `json:"password" validate:"required"`
Remark string `json:"remark"`
}
type NginxAuthReq struct {
WebsiteID uint `json:"websiteID" validate:"required"`
}