mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/1Panel-dev/1Panel.git
synced 2026-09-21 00:24:12 +08:00
* feat: Support batch import for Docker images * perf: Avoid duplicate Docker client creation in ImageLoad * style: Remove unnecessary comments in FileList component
61 lines
1.7 KiB
Go
61 lines
1.7 KiB
Go
package dto
|
|
|
|
import "time"
|
|
|
|
type PageImage struct {
|
|
PageInfo
|
|
Name string `json:"name"`
|
|
OrderBy string `json:"orderBy" validate:"required,oneof=size tags createdAt isUsed"`
|
|
Order string `json:"order" validate:"required,oneof=null ascending descending"`
|
|
}
|
|
|
|
type ImageInfo struct {
|
|
ID string `json:"id"`
|
|
CreatedAt time.Time `json:"createdAt"`
|
|
IsUsed bool `json:"isUsed"`
|
|
Tags []string `json:"tags"`
|
|
Size int64 `json:"size"`
|
|
|
|
IsPinned bool `json:"isPinned"`
|
|
Description string `json:"description"`
|
|
}
|
|
|
|
type ImageLoad struct {
|
|
TaskID string `json:"taskID"`
|
|
Paths []string `json:"paths" validate:"required,dive,required"`
|
|
}
|
|
|
|
type ImageBuild struct {
|
|
TaskID string `json:"taskID"`
|
|
From string `json:"from" validate:"required"`
|
|
Name string `json:"name" validate:"required"`
|
|
Dockerfile string `json:"dockerfile" validate:"required"`
|
|
Tags []string `json:"tags"`
|
|
Args []string `json:"args"`
|
|
}
|
|
|
|
type ImagePull struct {
|
|
TaskID string `json:"taskID"`
|
|
RepoID uint `json:"repoID"`
|
|
ImageName []string `json:"imageName" validate:"required"`
|
|
}
|
|
|
|
type ImageTag struct {
|
|
SourceID string `json:"sourceID" validate:"required"`
|
|
Tags []string `json:"tags" validate:"required"`
|
|
}
|
|
|
|
type ImagePush struct {
|
|
TaskID string `json:"taskID"`
|
|
RepoID uint `json:"repoID" validate:"required"`
|
|
TagName string `json:"tagName" validate:"required"`
|
|
Name string `json:"name" validate:"required"`
|
|
}
|
|
|
|
type ImageSave struct {
|
|
TaskID string `json:"taskID"`
|
|
TagName string `json:"tagName" validate:"required"`
|
|
Path string `json:"path" validate:"required"`
|
|
Name string `json:"name" validate:"required"`
|
|
}
|