application

package
v0.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 15, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	TypeName = map[Type]string{
		TypeSourceCode:     "SourceCode",
		TypeContainerImage: "ContainerImage",
		TypeOther:          "Other",
	}
)

Functions

This section is empty.

Types

type Application

type Application struct {
	Id       string    `json:"id" bson:"id"`
	CreateAt time.Time `json:"created_at" bson:"created_at"`
	UpdateAt time.Time `json:"updated_at" bson:"updated_at"`
	UpdateBy string    `json:"update_by" bson:"update_by"`
	CreateApplicationRequest
}

type CreateApplicationRequest

type CreateApplicationRequest struct {
	CreateBy  string `json:"create_by" bson:"create_by" description:"创建人"`
	Namespace string `` /* 127-byte string literal not displayed */
	CreateApplicationSpec
}

type CreateApplicationSpec

type CreateApplicationSpec struct {
	Name        string            `json:"name" bson:"name" description:"应用名称"`
	Description string            `json:"description" bson:"description" description:"应用描述"`
	Icon        string            `json:"icon" bson:"icon" description:"应用图标"`
	Type        Type              `json:"type" bson:"type" description:"应用类型, SourceCode, ContainerImage, Other"`
	GitURL      string            `json:"git_url" bson:"git_url" description:"应用代码仓库地址"`
	ImageURL    string            `json:"image_url" bson:"image_url" description:"应用容器镜像地址"`
	Owner       string            `json:"owner" bson:"owner" description:"应用所有者"`
	Level       uint32            `json:"level" bson:"level" description:"应用等级"`
	Priority    uint32            `json:"priority" bson:"priority" description:"应用优先级,用于控制应用启动的先后顺序"`
	Labels      map[string]string `json:"labels" bson:"labels" description:"应用标签,用于标识应用的特性,如:前端,后端,数据库等"`
}

type Service

type Service interface {
	CreateApplication(context.Context)
}

type Type

type Type int32
const (
	TypeSourceCode     Type = 0  // 源代码
	TypeContainerImage Type = 1  // 容器镜像
	TypeOther          Type = 15 // 其他类型
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL