release

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: Apache-2.0 Imports: 51 Imported by: 0

Documentation

Overview

Package recycle Release GC

Index

Constants

View Source
const (
	// AliYunRegistry Alibaba Cloud registry prefix
	AliYunRegistry = "registry.cn-hangzhou.aliyuncs.com"
)

Variables

This section is empty.

Functions

func GetApplicationId

func GetApplicationId(ctx context.Context) string

GetApplicationId .

func GetProjectID

func GetProjectID(ctx context.Context) string

GetProjectID .

func GetVersion

func GetVersion(ctx context.Context) string

GetVersion .

func ParseMetaFromReadCloser

func ParseMetaFromReadCloser(file io.ReadCloser) (*apistructs.ReleaseMetadata, map[string]string, error)

Types

type ReleaseService

type ReleaseService struct {
	Etcd        *clientv3.Client
	Config      *releaseConfig
	ReleaseRule *release_rule.ReleaseRule
	// contains filtered or unexported fields
}

func (*ReleaseService) CheckVersion

func (*ReleaseService) Convert

func (s *ReleaseService) Convert(releaseRequest *pb.ReleaseCreateRequest, appReleases []db.Release) (*db.Release, error)

Convert 从ReleaseRequest中提取Release元信息, 若为应用级制品, appReleases填nil

func (*ReleaseService) Create

func (s *ReleaseService) Create(req *pb.ReleaseCreateRequest) (string, error)

Create create Release

func (*ReleaseService) CreateByFile

func (s *ReleaseService) CreateByFile(req *pb.ReleaseUploadRequest, file io.ReadCloser) (string, string, error)

func (*ReleaseService) CreateRelease

CreateRelease POST /api/releases release create release

func (*ReleaseService) Delete

func (s *ReleaseService) Delete(orgID int64, opusMap map[string]*pb.ListArtifactsRespItem, releaseIDs ...string) error

Delete delete Release

func (*ReleaseService) DeleteRelease

func (*ReleaseService) DeleteReleases

func (*ReleaseService) Get

func (s *ReleaseService) Get(orgID int64, releaseID string) (*pb.ReleaseGetResponseData, error)

Get get Release

func (*ReleaseService) GetBranchLatestRelease

func (s *ReleaseService) GetBranchLatestRelease(projectID, appID int64, gitBranch string) (*db.Release, error)

GetBranchLatestRelease return the latest release with target gitBranch. return nil if not found.

func (*ReleaseService) GetDiceYAML

func (s *ReleaseService) GetDiceYAML(orgID int64, releaseID string) (string, error)

GetDiceYAML get dice.yml context

func (*ReleaseService) GetImages

func (s *ReleaseService) GetImages(dices []string) []*imagedb.Image

GetImages get image by ReleaseRequest

func (*ReleaseService) GetIosPlist

func (*ReleaseService) GetIosPlistService

func (s *ReleaseService) GetIosPlistService(orgID int64, releaseID string) (string, error)

GetIosPlist Read the download address plist in the ios type release

func (*ReleaseService) GetLatestReleases

func (*ReleaseService) GetLatestReleasesByProjectAndVersion

func (s *ReleaseService) GetLatestReleasesByProjectAndVersion(projectID int64, version string) (*[]db.Release, error)

GetLatestReleasesByProjectAndVersion get latelest Release by projectID & version

func (*ReleaseService) GetRelease

func (*ReleaseService) GetReleaseNamesByApp

func (s *ReleaseService) GetReleaseNamesByApp(orgID, appID int64) ([]string, error)

GetReleaseNamesByApp get releaseName list by appID

func (*ReleaseService) List

List Search based on search parameters

func (*ReleaseService) ListRelease

func (*ReleaseService) ListReleaseName

func (*ReleaseService) ParseReleaseFile

func (*ReleaseService) PutOffRelease

func (*ReleaseService) PutOnRelease

PutOnRelease puts on release to gallery. Internal call only

func (*ReleaseService) ReleaseGC

func (*ReleaseService) RemoveDeprecatedsReleases

func (s *ReleaseService) RemoveDeprecatedsReleases(now time.Time) error

RemoveDeprecatedsReleases Recycling expired release

func (*ReleaseService) ToFormal

func (s *ReleaseService) ToFormal(releaseIDs []string) error

func (*ReleaseService) ToFormalRelease

func (*ReleaseService) ToFormalReleases

func (*ReleaseService) Update

func (s *ReleaseService) Update(orgID int64, releaseID string, req *pb.ReleaseUpdateRequest) error

Update update Release

func (*ReleaseService) UpdateReference

func (s *ReleaseService) UpdateReference(orgID int64, releaseID string, req *pb.ReleaseReferenceUpdateRequest) error

UpdateReference update Release reference

func (*ReleaseService) UpdateRelease

func (*ReleaseService) UpdateReleaseReference

func (s *ReleaseService) UpdateReleaseReference(ctx context.Context, req *pb.ReleaseReferenceUpdateRequest) (*pb.ReleaseDataResponse, error)

func (*ReleaseService) UploadRelease

type ResourceType

type ResourceType string

ResourceType Release type

const (
	// ResourceTypeDiceYml ResourceType is dice.yml
	ResourceTypeDiceYml ResourceType = "diceyml"
	// ResourceTypeAddonYml ResourceType is addon.yml
	ResourceTypeAddonYml ResourceType = "addonyml"
	// ResourceTypeBinary ResourceType is binary executable
	ResourceTypeBinary ResourceType = "binary"
	// ResourceTypeScript ResourceType is executable script file, eg: shell/python/ruby, etc
	ResourceTypeScript ResourceType = "script"
	// ResourceTypeSQL ResourceType is sql
	ResourceTypeSQL ResourceType = "sql"
	// ResourceTypeDataSet ResourceType is Data text file
	ResourceTypeDataSet ResourceType = "data"
	// ResourceTypeAndroid ResourceType is android
	ResourceTypeAndroid ResourceType = "android"
	// ResourceTypeIOS ResourceType is ios
	ResourceTypeIOS ResourceType = "ios"
	// ResourceTypeMigration ResourceType is migration文件releaseID
	ResourceTypeMigration ResourceType = "migration"
	// ResourceTypeH5 ResourceType is h5
	ResourceTypeH5 ResourceType = "h5"
)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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