Documentation
¶
Index ¶
- Constants
- func GetTransformedDataForSecretConfigData(data string, mode util.SecretTransformMode) (string, error)
- func IsGitStorage(storageType string) bool
- type AppDeleteResponseDTO
- type AppLabelDto
- type AppLabelsDto
- type AppLabelsJsonForDeployment
- type AppMetaInfoDto
- type BuildBinaryConfig
- type CDMaterialMetadata
- type CDPatchRequest
- type CDPipelineAddType
- type CDPipelineConfigObject
- func (cdPipelineConfig *CDPipelineConfigObject) GetReleaseMode() string
- func (cdPipelineConfig *CDPipelineConfigObject) IsExternalArgoAppLinkRequest() bool
- func (cdPipelineConfig *CDPipelineConfigObject) IsExternalHelmAppLinkRequest() bool
- func (cdPipelineConfig *CDPipelineConfigObject) IsLinkedRelease() bool
- func (cdPipelineConfig *CDPipelineConfigObject) IsSwitchCiPipelineRequest() bool
- func (cdPipelineConfig *CDPipelineConfigObject) PatchSourceInfo() (int, string)
- type CDPipelineMinConfig
- type CDPipelineViewObject
- type CDSourceObject
- type CdBulkAction
- type CdBulkActionRequestDto
- type CdBulkActionResponseDto
- type CdPatchAction
- type CdPipelineTrigger
- type CdPipelines
- type CdStage
- type ChartUsedDto
- type CiArtifactBean
- type CiArtifactResponse
- type CiConfigRequest
- type CiMaterial
- type CiMaterialBulkPatchRequest
- type CiMaterialBulkPatchResponse
- type CiMaterialPatchRequest
- type CiMaterialPatchResponse
- type CiMaterialValuePatchRequest
- type CiPatchMessage
- type CiPatchRequest
- type CiPatchStatus
- type CiPipeline
- type CiPipelineMaterial
- type CiPipelineMin
- type CiPipelineMinResponse
- type CiRegexPatchRequest
- type CiScript
- type CiTrigger
- type CiTriggerRequest
- type ConfigData
- type ConfigList
- type CreateAppDTO
- type CreateMaterialDTO
- type CustomTagData
- type DeploymentAppTypeChangeRequest
- type DeploymentAppTypeChangeResponse
- type DeploymentChangeStatus
- type DockerConfigOverride
- type ESOData
- type ESOSecretData
- type Environment
- type EnvironmentGroup
- type ErrorDto
- type ExampleValueDto
- type ExposeType
- type ExternalCiConfig
- type ExternalCiConfigRole
- type ExternalSecret
- type GitCiTriggerRequest
- type GitMaterial
- type GitMaterialMetaDto
- type HelmConfig
- type Job
- type JsonPath
- type Label
- type ManifestStorage
- type Material
- type MaterialMetadata
- type MaterialOperations
- type MonitoringConfig
- type PackagingConfig
- type PatchAction
- type PayloadOptionObject
- type Pipeline
- type PipelineCreateResponse
- type PostStageConfigMapSecretNames
- type PreStageConfigMapSecretNames
- type PropertiesConfig
- type ResponseDescriptionSchemaObject
- type ResponseSchemaObject
- type Rollback
- type SchemaObject
- type Scheme
- type SecretList
- type ServiceExposeConfig
- type SourceType
- type SourceTypeConfig
- type Stage
- type Status
- type Strategy
- type Task
- type Test
- type TestExecutorImageProperties
- type ThirdPartyMonitoringConfig
- type TriggerViewCiConfig
- type UpdateMaterialDTO
- type UpdateProjectBulkAppsRequest
- type WorkflowCacheConfig
Constants ¶
const ( LayoutISO = "2006-01-02 15:04:05" LayoutUS = "January 2, 2006 15:04:05" LayoutRFC3339 = "2006-01-02T15:04:05Z07:00" LayoutDDMMYY_HHMM12hr = "2 January,2006 15.04PM" )
const ( CASCADE_DELETE int = iota NON_CASCADE_DELETE FORCE_DELETE )
const ( WEBHOOK_SELECTOR_UNIQUE_ID_NAME string = "unique id" WEBHOOK_SELECTOR_REPOSITORY_URL_NAME string = "repository url" WEBHOOK_SELECTOR_HEADER_NAME string = "header" WEBHOOK_SELECTOR_GIT_URL_NAME string = "git url" WEBHOOK_SELECTOR_AUTHOR_NAME string = "author" WEBHOOK_SELECTOR_DATE_NAME string = "date" WEBHOOK_SELECTOR_TARGET_CHECKOUT_NAME string = "target checkout" WEBHOOK_SELECTOR_SOURCE_CHECKOUT_NAME string = "source checkout" WEBHOOK_SELECTOR_TARGET_BRANCH_NAME_NAME string = "target branch name" WEBHOOK_SELECTOR_SOURCE_BRANCH_NAME_NAME string = "source branch name" WEBHOOK_EVENT_MERGED_ACTION_TYPE string = "merged" WEBHOOK_EVENT_NON_MERGED_ACTION_TYPE string = "non-merged" )
const ( EXPOSE_INTERNAL ExposeType = "clusterIp" EXPOSE_EXTERNAL ExposeType = "elb" SCHEME_HTTP Scheme = "http" SCHEME_HTTPS Scheme = "https" SCHEME_TCP Scheme = "tcp" )
const CustomAutoScalingEnabledPathKey = "CUSTOM_AUTOSCALING_ENABLED_PATH"
const CustomAutoscalingMaxPathKey = "CUSTOM_AUTOSCALING_MAX_PATH"
const CustomAutoscalingMinPathKey = "CUSTOM_AUTOSCALING_MIN_PATH"
const CustomAutoscalingReplicaCountPathKey = "CUSTOM_AUTOSCALING_REPLICA_COUNT_PATH"
const (
HelmReleaseMetadataAnnotation = `` /* 156-byte string literal not displayed */
)
const NOT_FOUND = "not found"
const RELEASE_NOT_EXIST = "release not exist"
Variables ¶
This section is empty.
Functions ¶
func GetTransformedDataForSecretConfigData ¶ added in v1.0.0
func GetTransformedDataForSecretConfigData(data string, mode util.SecretTransformMode) (string, error)
func IsGitStorage ¶ added in v0.6.19
Types ¶
type AppDeleteResponseDTO ¶ added in v0.6.18
type AppLabelDto ¶ added in v0.2.23
type AppLabelsDto ¶ added in v0.2.23
type AppLabelsJsonForDeployment ¶ added in v0.5.3
type AppMetaInfoDto ¶ added in v0.2.21
type AppMetaInfoDto struct {
AppId int `json:"appId"`
AppName string `json:"appName"`
Description string `json:"description"`
ProjectId int `json:"projectId"`
ProjectName string `json:"projectName"`
CreatedBy string `json:"createdBy"`
CreatedOn time.Time `json:"createdOn"`
Active bool `json:"active,notnull"`
Labels []*Label `json:"labels"`
Note *bean2.GenericNoteResponseBean `json:"note"`
UserId int32 `json:"-"`
//below field is only valid for helm apps
ChartUsed *ChartUsedDto `json:"chartUsed,omitempty"`
GitMaterials []*GitMaterialMetaDto `json:"gitMaterials,omitempty"`
}
type BuildBinaryConfig ¶
type BuildBinaryConfig struct {
Name string `json:"name"`
Stages []Stage `json:"stages"` //stages will be executed sequentially
}
user should be able to compose multiple sequential and parallel steps for building binary.
type CDMaterialMetadata ¶
type CDMaterialMetadata struct {
Url string `json:"url,omitempty"`
Branch string `json:"branch,omitempty"`
Tag string `json:"tag,omitempty"`
}
--------- cd related struct ---------
type CDPatchRequest ¶
type CDPatchRequest struct {
Pipeline *CDPipelineConfigObject `json:"pipeline,omitempty"`
AppId int `json:"appId,omitempty"`
Action CdPatchAction `json:"action,omitempty"`
UserId int32 `json:"-"`
ForceDelete bool `json:"-"`
NonCascadeDelete bool `json:"-"`
}
type CDPipelineAddType ¶ added in v0.6.28
type CDPipelineAddType string
const ( SEQUENTIAL CDPipelineAddType = "SEQUENTIAL" PARALLEL CDPipelineAddType = "PARALLEL" )
type CDPipelineConfigObject ¶
type CDPipelineConfigObject struct {
Id int `json:"id,omitempty" validate:"number" `
EnvironmentId int `json:"environmentId,omitempty" validate:"number,required" `
EnvironmentName string `json:"environmentName,omitempty" `
Description string `json:"description" validate:"max=40"`
CiPipelineId int `json:"ciPipelineId,omitempty" validate:"number"`
TriggerType pipelineConfig.TriggerType `json:"triggerType,omitempty" validate:"oneof=AUTOMATIC MANUAL"`
Name string `json:"name,omitempty" validate:"name-component,max=50"` //pipelineName
Strategies []Strategy `json:"strategies,omitempty"`
Namespace string `json:"namespace,omitempty"` //namespace
AppWorkflowId int `json:"appWorkflowId,omitempty" `
DeploymentTemplate chartRepoRepository.DeploymentStrategy `json:"deploymentTemplate,omitempty"` //
PreStage CdStage `json:"preStage,omitempty"`
PostStage CdStage `json:"postStage,omitempty"`
PreStageConfigMapSecretNames PreStageConfigMapSecretNames `json:"preStageConfigMapSecretNames,omitempty"`
PostStageConfigMapSecretNames PostStageConfigMapSecretNames `json:"postStageConfigMapSecretNames,omitempty"`
RunPreStageInEnv bool `json:"runPreStageInEnv,omitempty"`
RunPostStageInEnv bool `json:"runPostStageInEnv,omitempty"`
CdArgoSetup bool `json:"isClusterCdActive"`
ParentPipelineId int `json:"parentPipelineId"`
ParentPipelineType string `json:"parentPipelineType"`
DeploymentAppType string `json:"deploymentAppType"`
AppName string `json:"appName"`
DeploymentAppDeleteRequest bool `json:"deploymentAppDeleteRequest"`
DeploymentAppCreated bool `json:"deploymentAppCreated"`
AppId int `json:"appId"`
TeamId int `json:"-"`
EnvironmentIdentifier string `json:"-" `
IsVirtualEnvironment bool `json:"isVirtualEnvironment"`
HelmPackageName string `json:"helmPackageName"`
ChartName string `json:"chartName"`
ChartBaseVersion string `json:"chartBaseVersion"`
ContainerRegistryId int `json:"containerRegistryId"`
RepoUrl string `json:"repoUrl"`
ManifestStorageType string `json:"manifestStorageType"`
PreDeployStage *bean.PipelineStageDto `json:"preDeployStage,omitempty"`
PostDeployStage *bean.PipelineStageDto `json:"postDeployStage,omitempty"`
SourceToNewPipelineId map[int]int `json:"sourceToNewPipelineId,omitempty"`
RefPipelineId int `json:"refPipelineId,omitempty"`
ExternalCiPipelineId int `json:"externalCiPipelineId,omitempty"`
CustomTagObject *CustomTagData `json:"customTag"`
CustomTagStage *repository.PipelineStageType `json:"customTagStage"`
EnableCustomTag bool `json:"enableCustomTag"`
IsGitOpsRepoNotConfigured bool `json:"isGitOpsRepoNotConfigured"`
SwitchFromCiPipelineId int `json:"switchFromCiPipelineId"`
CDPipelineAddType CDPipelineAddType `json:"addType"`
ChildPipelineId int `json:"childPipelineId"`
IsDigestEnforcedForPipeline bool `json:"isDigestEnforcedForPipeline"`
IsDigestEnforcedForEnv bool `json:"isDigestEnforcedForEnv"`
ApplicationObjectClusterId int `json:"applicationObjectClusterId"` //ACDAppClusterId
ApplicationObjectNamespace string `json:"applicationObjectNamespace"` //ACDAppNamespace
DeploymentAppName string `json:"deploymentAppName"`
ReleaseMode string `json:"releaseMode" validate:"omitempty,oneof=link create"`
}
func (*CDPipelineConfigObject) GetReleaseMode ¶ added in v1.4.0
func (cdPipelineConfig *CDPipelineConfigObject) GetReleaseMode() string
func (*CDPipelineConfigObject) IsExternalArgoAppLinkRequest ¶ added in v1.4.0
func (cdPipelineConfig *CDPipelineConfigObject) IsExternalArgoAppLinkRequest() bool
func (*CDPipelineConfigObject) IsExternalHelmAppLinkRequest ¶ added in v1.4.0
func (cdPipelineConfig *CDPipelineConfigObject) IsExternalHelmAppLinkRequest() bool
func (*CDPipelineConfigObject) IsLinkedRelease ¶ added in v1.4.0
func (cdPipelineConfig *CDPipelineConfigObject) IsLinkedRelease() bool
func (*CDPipelineConfigObject) IsSwitchCiPipelineRequest ¶ added in v0.6.26
func (cdPipelineConfig *CDPipelineConfigObject) IsSwitchCiPipelineRequest() bool
func (*CDPipelineConfigObject) PatchSourceInfo ¶ added in v1.0.0
func (cdPipelineConfig *CDPipelineConfigObject) PatchSourceInfo() (int, string)
type CDPipelineMinConfig ¶ added in v1.4.0
type CDPipelineViewObject ¶
type CDPipelineViewObject struct {
Id int `json:"id"`
PipelineCounter int `json:"pipelineCounter"`
Environment string `json:"environment"`
Downstream []int `json:"downstream"` //PipelineCounter of downstream
Status string `json:"status"`
Message string `json:"message"`
ProgressText string `json:"progress_text"`
PipelineType pipelineConfig.PipelineType `json:"pipelineType"`
GitDiffUrl string `json:"git_diff_url"`
PipelineHistoryUrl string `json:"pipeline_history_url"` //remove
Rollback Rollback `json:"rollback"`
Name string `json:"-"`
CDSourceObject
}
type CDSourceObject ¶
type CDSourceObject struct {
Id int `json:"id"`
DisplayName string `json:"displayName"`
Metadata CDMaterialMetadata `json:"metadata"`
}
type CdBulkAction ¶ added in v0.6.4
type CdBulkAction int
const (
CD_BULK_DELETE CdBulkAction = iota
)
type CdBulkActionRequestDto ¶ added in v0.6.4
type CdBulkActionResponseDto ¶ added in v0.6.4
type CdPatchAction ¶
type CdPatchAction int
const ( CD_CREATE CdPatchAction = iota CD_DELETE //delete this pipeline CD_UPDATE CD_DELETE_PARTIAL // Partially delete means it will only delete ACD app )
func (CdPatchAction) String ¶
func (a CdPatchAction) String() string
type CdPipelineTrigger ¶ added in v0.6.13
type CdPipelines ¶
type CdPipelines struct {
Pipelines []*CDPipelineConfigObject `json:"pipelines,omitempty" validate:"dive"`
AppId int `json:"appId,omitempty" validate:"number,required" `
UserId int32 `json:"-"`
IsCloneAppReq bool `json:"-"`
AppDeleteResponse *AppDeleteResponseDTO `json:"deleteResponse,omitempty"`
}
type CdStage ¶
type CdStage struct {
TriggerType pipelineConfig.TriggerType `json:"triggerType,omitempty"`
Name string `json:"name,omitempty"`
Status string `json:"status,omitempty"`
Config string `json:"config,omitempty"`
}
type ChartUsedDto ¶ added in v0.6.26
type ChartUsedDto struct {
AppStoreChartName string `json:"appStoreChartName,omitempty"`
AppStoreChartId int `json:"appStoreChartId,omitempty"`
AppStoreAppName string `json:"appStoreAppName,omitempty"`
AppStoreAppVersion string `json:"appStoreAppVersion,omitempty"`
ChartAvatar string `json:"chartAvatar,omitempty"`
}
type CiArtifactBean ¶
type CiArtifactBean struct {
Id int `json:"id"`
Image string `json:"image,notnull"`
ImageDigest string `json:"image_digest,notnull"`
MaterialInfo json.RawMessage `json:"material_info"` //git material metadata json array string
DataSource string `json:"data_source,notnull"`
DeployedTime string `json:"deployed_time"`
Deployed bool `json:"deployed,notnull"`
Latest bool `json:"latest,notnull"`
LastSuccessfulTriggerOnParent bool `json:"lastSuccessfulTriggerOnParent,notnull"`
RunningOnParentCd bool `json:"runningOnParentCd,omitempty"`
IsVulnerable bool `json:"vulnerable,notnull"`
ScanEnabled bool `json:"scanEnabled,notnull"`
Scanned bool `json:"scanned,notnull"`
WfrId int `json:"wfrId"`
DeployedBy string `json:"deployedBy"`
CiConfigureSourceType constants.SourceType `json:"ciConfigureSourceType"`
CiConfigureSourceValue string `json:"ciConfigureSourceValue"`
ImageReleaseTags []*repository2.ImageTag `json:"imageReleaseTags"`
ImageComment *repository2.ImageComment `json:"imageComment"`
CreatedTime string `json:"createdTime"`
ExternalCiPipelineId int `json:"-"`
ParentCiArtifact int `json:"-"`
CiWorkflowId int `json:"-"`
RegistryType string `json:"registryType"`
RegistryName string `json:"registryName"`
TargetPlatforms []*bean4.TargetPlatform `json:"targetPlatforms"`
CiPipelineId int `json:"-"`
CredentialsSourceType string `json:"-"`
CredentialsSourceValue string `json:"-"`
}
type CiArtifactResponse ¶
type CiArtifactResponse struct {
//AppId int `json:"app_id"`
CdPipelineId int `json:"cd_pipeline_id,notnull"`
LatestWfArtifactId int `json:"latest_wf_artifact_id"`
LatestWfArtifactStatus string `json:"latest_wf_artifact_status"`
CiArtifacts []CiArtifactBean `json:"ci_artifacts,notnull"`
TagsEditable bool `json:"tagsEditable"`
AppReleaseTagNames []string `json:"appReleaseTagNames"` //unique list of tags exists in the app
HideImageTaggingHardDelete bool `json:"hideImageTaggingHardDelete"`
TotalCount int `json:"totalCount"`
}
type CiConfigRequest ¶
type CiConfigRequest struct {
Id int `json:"id,omitempty" validate:"number"` //ciTemplateId
AppId int `json:"appId,omitempty" validate:"required,number"`
DockerRegistry string `json:"dockerRegistry,omitempty" ` //repo id example ecr mapped one-one with gocd registry entry
DockerRepository string `json:"dockerRepository,omitempty"` // example test-app-1 which is inside ecr
CiBuildConfig *CiPipeline2.CiBuildConfigBean `json:"ciBuildConfig"`
CiPipelines []*CiPipeline `json:"ciPipelines,omitempty" validate:"dive"` //a pipeline will be built for each ciMaterial
AppName string `json:"appName,omitempty"`
Version string `json:"version,omitempty"` //gocd etag used for edit purpose
DockerRegistryUrl string `json:"-"`
CiTemplateName string `json:"-"`
UserId int32 `json:"-"`
Materials []Material `json:"materials"`
AppWorkflowId int `json:"appWorkflowId,omitempty"`
BeforeDockerBuild []*Task `json:"beforeDockerBuild,omitempty" validate:"dive"`
AfterDockerBuild []*Task `json:"afterDockerBuild,omitempty" validate:"dive"`
ScanEnabled bool `json:"scanEnabled,notnull"`
CreatedOn time.Time `sql:"created_on,type:timestamptz"`
CreatedBy int32 `sql:"created_by,type:integer"`
UpdatedOn time.Time `sql:"updated_on,type:timestamptz"`
UpdatedBy int32 `sql:"updated_by,type:integer"`
IsJob bool `json:"-"`
CiGitMaterialId int `json:"ciGitConfiguredId"`
IsCloneJob bool `json:"isCloneJob,omitempty"`
AppWorkflowMapping *appWorkflow.AppWorkflowMapping `json:"-"`
Artifact *repository3.CiArtifact `json:"-"`
}
type CiMaterial ¶
type CiMaterial struct {
Source *SourceTypeConfig `json:"source,omitempty" validate:"dive,required"` //branch for ci
Path string `json:"path,omitempty"` // defaults to root of git repo
CheckoutPath string `json:"checkoutPath,omitempty"` //path where code will be checked out for single source `./` default for multiSource configured by user
GitMaterialId int `json:"gitMaterialId,omitempty" validate:"required"` //id stored in db GitMaterial( foreign key)
ScmId string `json:"scmId,omitempty"` //id of gocd object
ScmName string `json:"scmName,omitempty"`
ScmVersion string `json:"scmVersion,omitempty"`
Id int `json:"id,omitempty"`
GitMaterialName string `json:"gitMaterialName"`
IsRegex bool `json:"isRegex"`
}
type CiMaterialBulkPatchRequest ¶ added in v0.6.24
type CiMaterialBulkPatchResponse ¶ added in v0.6.24
type CiMaterialBulkPatchResponse struct {
Apps []CiMaterialPatchResponse `json:"apps"`
}
type CiMaterialPatchRequest ¶ added in v0.6.21
type CiMaterialPatchRequest struct {
AppId int `json:"appId" validate:"required"`
EnvironmentId int `json:"environmentId" validate:"required"`
Source *SourceTypeConfig `json:"source" validate:"required"`
}
type CiMaterialPatchResponse ¶ added in v0.6.24
type CiMaterialPatchResponse struct {
AppId int `json:"appId"`
Status CiPatchStatus `json:"status"`
Message string `json:"message"`
}
type CiMaterialValuePatchRequest ¶ added in v0.6.24
type CiPatchMessage ¶ added in v0.6.24
type CiPatchMessage string
const ( CI_PATCH_NOT_AUTHORIZED_MESSAGE CiPatchMessage = "You don't have permission to change branch" CI_PATCH_MULTI_GIT_ERROR CiPatchMessage = "Build pipeline is connected to multiple git repositories" CI_PATCH_REGEX_ERROR CiPatchMessage = "Provided branch does not match regex " CI_BRANCH_TYPE_ERROR CiPatchMessage = "Branch cannot be changed for pipeline as source type is “Pull request or Tag”" CI_PATCH_SKIP_MESSAGE CiPatchMessage = "Skipped for pipeline as source type is " )
type CiPatchRequest ¶
type CiPatchRequest struct {
CiPipeline *CiPipeline `json:"ciPipeline" validate:"omitempty,dive"`
AppId int `json:"appId,omitempty"`
Action PatchAction `json:"action"`
AppWorkflowId int `json:"appWorkflowId,omitempty"`
UserId int32 `json:"-"`
IsJob bool `json:"-"`
IsCloneJob bool `json:"isCloneJob,omitempty"`
ParentCDPipeline int `json:"parentCDPipeline"`
DeployEnvId int `json:"deployEnvId"`
SwitchFromCiPipelineId int `json:"switchFromCiPipelineId"`
SwitchFromExternalCiPipelineId int `json:"switchFromExternalCiPipelineId"`
SwitchFromCiPipelineType CiPipeline2.PipelineType `json:"-"`
SwitchToCiPipelineType CiPipeline2.PipelineType `json:"-"`
}
func (CiPatchRequest) IsCreateRequest ¶ added in v0.7.2
func (ciPatchRequest CiPatchRequest) IsCreateRequest() bool
func (CiPatchRequest) IsSwitchCiPipelineRequest ¶ added in v0.6.26
func (ciPatchRequest CiPatchRequest) IsSwitchCiPipelineRequest() bool
func (CiPatchRequest) PatchSourceInfo ¶ added in v0.7.3
func (ciPatchRequest CiPatchRequest) PatchSourceInfo() (int, string)
PatchSourceInfo returns the CI component ID and component Type, which is being patched
func (CiPatchRequest) SwitchSourceInfo ¶ added in v0.7.2
func (ciPatchRequest CiPatchRequest) SwitchSourceInfo() (int, CiPipeline2.PipelineType)
type CiPatchStatus ¶ added in v0.6.24
type CiPatchStatus string
const ( CI_PATCH_SUCCESS CiPatchStatus = "Succeeded" CI_PATCH_FAILED CiPatchStatus = "Failed" CI_PATCH_NOT_AUTHORIZED CiPatchStatus = "Not authorised" CI_PATCH_SKIP CiPatchStatus = "Skipped" )
type CiPipeline ¶
type CiPipeline struct {
IsManual bool `json:"isManual"`
DockerArgs map[string]string `json:"dockerArgs"`
IsExternal bool `json:"isExternal"`
ParentCiPipeline int `json:"parentCiPipeline"`
ParentAppId int `json:"parentAppId"`
AppId int `json:"appId"`
AppName string `json:"appName,omitempty"`
AppType helper.AppType `json:"appType,omitempty"`
ExternalCiConfig ExternalCiConfig `json:"externalCiConfig"`
CiMaterial []*CiMaterial `json:"ciMaterial,omitempty" validate:"dive,min=1"`
Name string `json:"name,omitempty" validate:"name-component,max=100"` // name suffix of corresponding pipeline. required, unique, validation corresponding to gocd pipelineName will be applicable
Id int `json:"id,omitempty" `
Version string `json:"version,omitempty"` // matchIf token version in gocd . used for update request
Active bool `json:"active,omitempty"` // pipeline is active or not
Deleted bool `json:"deleted,omitempty"`
BeforeDockerBuild []*Task `json:"beforeDockerBuild,omitempty" validate:"dive"`
AfterDockerBuild []*Task `json:"afterDockerBuild,omitempty" validate:"dive"`
BeforeDockerBuildScripts []*CiScript `json:"beforeDockerBuildScripts,omitempty" validate:"dive"`
AfterDockerBuildScripts []*CiScript `json:"afterDockerBuildScripts,omitempty" validate:"dive"`
LinkedCount int `json:"linkedCount"`
PipelineType CiPipeline2.PipelineType `json:"pipelineType,omitempty"`
ScanEnabled bool `json:"scanEnabled,notnull"`
AppWorkflowId int `json:"appWorkflowId,omitempty"`
PreBuildStage *bean.PipelineStageDto `json:"preBuildStage,omitempty" validate:"omitempty,dive"`
PostBuildStage *bean.PipelineStageDto `json:"postBuildStage,omitempty" validate:"omitempty,dive"`
TargetPlatform string `json:"targetPlatform,omitempty"`
IsDockerConfigOverridden bool `json:"isDockerConfigOverridden"`
DockerConfigOverride DockerConfigOverride `json:"dockerConfigOverride,omitempty"`
EnvironmentId int `json:"environmentId,omitempty"`
LastTriggeredEnvId int `json:"lastTriggeredEnvId"`
CustomTagObject *CustomTagData `json:"customTag,omitempty"`
DefaultTag []string `json:"defaultTag,omitempty"`
EnableCustomTag bool `json:"enableCustomTag"`
}
func (*CiPipeline) IsLinkedCi ¶ added in v0.7.2
func (ciPipeline *CiPipeline) IsLinkedCi() bool
type CiPipelineMaterial ¶
type CiPipelineMin ¶
type CiPipelineMin struct {
Name string `json:"name,omitempty" validate:"name-component,max=100"` //name suffix of corresponding pipeline. required, unique, validation corresponding to gocd pipelineName will be applicable
Id int `json:"id,omitempty" `
Version string `json:"version,omitempty"` //matchIf token version in gocd . used for update request
IsExternal bool `json:"isExternal,omitempty"`
ParentCiPipeline int `json:"parentCiPipeline"`
ParentAppId int `json:"parentAppId"`
PipelineType CiPipeline2.PipelineType `json:"pipelineType,omitempty"`
ScanEnabled bool `json:"scanEnabled,notnull"`
}
type CiPipelineMinResponse ¶ added in v0.6.17
type CiPipelineMinResponse struct {
Id int `json:"id,omitempty" validate:"number"` //ciTemplateId
AppId int `json:"appId,omitempty" validate:"required,number"`
AppName string `json:"appName,omitempty"`
ParentCiPipeline int `json:"parentCiPipeline"`
ParentAppId int `json:"parentAppId"`
PipelineType string `json:"pipelineType"`
}
type CiRegexPatchRequest ¶ added in v0.4.28
type CiRegexPatchRequest struct {
CiPipelineMaterial []*CiPipelineMaterial `json:"ciPipelineMaterial,omitempty"`
Id int `json:"id,omitempty" `
AppId int `json:"appId,omitempty"`
UserId int32 `json:"-"`
}
type CiTriggerRequest ¶
type CiTriggerRequest struct {
PipelineId int `json:"pipelineId"`
CiPipelineMaterial []CiPipelineMaterial `json:"ciPipelineMaterials" validate:"required"`
TriggeredBy int32 `json:"triggeredBy"`
InvalidateCache bool `json:"invalidateCache"`
EnvironmentId int `json:"environmentId"`
PipelineType string `json:"pipelineType"`
CiArtifactLastFetch time.Time `json:"ciArtifactLastFetch"`
}
type ConfigData ¶ added in v0.6.26
type ConfigData struct {
Name string `json:"name"`
Type string `json:"type"`
External bool `json:"external"`
MountPath string `json:"mountPath,omitempty"`
Data json.RawMessage `json:"data"`
DefaultData json.RawMessage `json:"defaultData,omitempty"`
DefaultMountPath string `json:"defaultMountPath,omitempty"`
Global bool `json:"global"`
ExternalSecretType string `json:"externalType"`
ExternalSecret []ExternalSecret `json:"secretData"`
DefaultExternalSecret []ExternalSecret `json:"defaultSecretData,omitempty"`
ESOSecretData ESOSecretData `json:"esoSecretData"`
DefaultESOSecretData ESOSecretData `json:"defaultESOSecretData,omitempty"`
RoleARN string `json:"roleARN"`
SubPath bool `json:"subPath"`
ESOSubPath []string `json:"esoSubPath"`
FilePermission string `json:"filePermission"`
Overridden bool `json:"overridden"`
}
TODO refactoring: duplicate struct of ConfigData in ConfigMapBean.go
func (*ConfigData) IsESOExternalSecretType ¶ added in v1.0.0
func (c *ConfigData) IsESOExternalSecretType() bool
type ConfigList ¶ added in v0.6.26
type ConfigList struct {
ConfigData []*ConfigData `json:"maps"`
}
type CreateAppDTO ¶
type CreateAppDTO struct {
Id int `json:"id,omitempty" validate:"number"`
AppName string `json:"appName" validate:"name-component,max=100"`
Description string `json:"description"`
UserId int32 `json:"-"` //not exposed to UI
Material []*GitMaterial `json:"material" validate:"dive,min=1"`
TeamId int `json:"teamId,omitempty" validate:"number,required"`
TemplateId int `json:"templateId"`
AppLabels []*Label `json:"labels,omitempty" validate:"dive"`
GenericNote *bean2.GenericNoteResponseBean `json:"genericNote,omitempty"`
AppType helper.AppType `json:"appType" validate:"gt=-1,lt=3"` //TODO: Change Validation if new AppType is introduced
DisplayName string `json:"-"` //not exposed to UI
}
type CreateMaterialDTO ¶
type CreateMaterialDTO struct {
Id int `json:"id,omitempty" validate:"number"`
AppId int `json:"appId" validate:"number"`
Material []*GitMaterial `json:"material" validate:"dive,min=1"`
UserId int32 `json:"-"` //not exposed to UI
}
type CustomTagData ¶ added in v0.6.25
type DeploymentAppTypeChangeRequest ¶ added in v0.6.13
type DeploymentAppTypeChangeRequest struct {
EnvId int `json:"envId,omitempty" validate:"required"`
DesiredDeploymentType bean3.DeploymentType `json:"desiredDeploymentType,omitempty" validate:"required"`
ExcludeApps []int `json:"excludeApps"`
IncludeApps []int `json:"includeApps"`
AutoTriggerDeployment bool `json:"autoTriggerDeployment"`
UserId int32 `json:"-"`
}
type DeploymentAppTypeChangeResponse ¶ added in v0.6.13
type DeploymentAppTypeChangeResponse struct {
EnvId int `json:"envId,omitempty"`
DesiredDeploymentType bean3.DeploymentType `json:"desiredDeploymentType,omitempty"`
SuccessfulPipelines []*DeploymentChangeStatus `json:"successfulPipelines"`
FailedPipelines []*DeploymentChangeStatus `json:"failedPipelines"`
TriggeredPipelines []*CdPipelineTrigger `json:"-"` // Disabling auto-trigger until bulk trigger API is fixed
}
DeploymentAppTypeChangeResponse is used as response obj for migrating devtron apps as well as chart store apps
type DeploymentChangeStatus ¶ added in v0.6.13
type DeploymentChangeStatus struct {
PipelineId int `json:"pipelineId,omitempty"`
InstalledAppId int `json:"installedAppId,omitempty"`
AppId int `json:"appId,omitempty"`
AppName string `json:"appName,omitempty"`
EnvId int `json:"envId,omitempty"`
EnvName string `json:"envName,omitempty"`
Error string `json:"error,omitempty"`
Status Status `json:"status,omitempty"`
}
type DockerConfigOverride ¶ added in v0.6.0
type DockerConfigOverride struct {
DockerRegistry string `json:"dockerRegistry,omitempty"`
DockerRepository string `json:"dockerRepository,omitempty"`
CiBuildConfig *CiPipeline2.CiBuildConfigBean `json:"ciBuildConfig,omitEmpty"`
}
type ESOSecretData ¶ added in v0.6.26
type ESOSecretData struct {
SecretStore json.RawMessage `json:"secretStore,omitempty"`
SecretStoreRef json.RawMessage `json:"secretStoreRef,omitempty"`
ESOData []ESOData `json:"esoData"`
RefreshInterval string `json:"refreshInterval,omitempty"`
ESODataFrom json.RawMessage `json:"esoDataFrom,omitempty"`
Template json.RawMessage `json:"template,omitempty"`
}
type Environment ¶
type Environment struct {
Values string
}
set of unique attributes which corresponds to a cluster different environment of gocd and k8s cluster.
type EnvironmentGroup ¶
type EnvironmentGroup struct {
Name string
Environments []Environment
}
if Environments has multiple entries then application of them will be deployed simultaneously
type ExampleValueDto ¶ added in v0.6.9
type ExposeType ¶
type ExposeType string
type ExternalCiConfig ¶
type ExternalCiConfig struct {
Id int `json:"id"`
WebhookUrl string `json:"webhookUrl"`
Payload string `json:"payload"`
AccessKey string `json:"accessKey"`
PayloadOption []PayloadOptionObject `json:"payloadOption"`
Schema map[string]interface{} `json:"schema"`
Responses []ResponseSchemaObject `json:"responses"`
ExternalCiConfigRole
}
type ExternalCiConfigRole ¶ added in v0.6.9
type ExternalCiConfigRole struct {
ProjectId int `json:"projectId"`
ProjectName string `json:"projectName"`
EnvironmentId string `json:"environmentId"`
EnvironmentName string `json:"environmentName"`
EnvironmentIdentifier string `json:"environmentIdentifier"`
AppId int `json:"appId"`
AppName string `json:"appName"`
Role string `json:"role"`
}
type ExternalSecret ¶ added in v0.6.26
type GitCiTriggerRequest ¶
type GitCiTriggerRequest struct {
CiPipelineMaterial CiPipelineMaterial `json:"ciPipelineMaterial" validate:"required"`
TriggeredBy int32 `json:"triggeredBy"`
ExtraEnvironmentVariables map[string]string `json:"extraEnvironmentVariables"` // extra env variables which will be used for CI
}
type GitMaterial ¶
type GitMaterial struct {
Name string `json:"name,omitempty" ` //not null, //default format pipelineGroup.AppName + "-" + inputMaterial.Name,
Url string `json:"url,omitempty"` //url of git repo
Id int `json:"id,omitempty" validate:"number"`
GitProviderId int `json:"gitProviderId,omitempty" validate:"gt=0"`
CheckoutPath string `json:"checkoutPath" validate:"checkout-path-component"`
FetchSubmodules bool `json:"fetchSubmodules"`
IsUsedInCiConfig bool `json:"isUsedInCiConfig"`
FilterPattern []string `json:"filterPattern"`
CreateBackup bool `json:"createBackup"`
}
func (*GitMaterial) UpdateSanitisedGitRepoUrl ¶ added in v0.6.29
func (m *GitMaterial) UpdateSanitisedGitRepoUrl()
UpdateSanitisedGitRepoUrl will remove all trailing slashes , leading and trailing spaces from git repository url
type GitMaterialMetaDto ¶ added in v0.6.26
type HelmConfig ¶
type HelmConfig struct {
}
contains reference to chart and values.yaml changes for next deploy
type JsonPath ¶ added in v0.7.2
type JsonPath string
const ConfigHashPathKey JsonPath = "devtronInternal.containerSpecs.ConfigHash"
const SecretHashPathKey JsonPath = "devtronInternal.containerSpecs.SecretHash"
type ManifestStorage ¶ added in v0.6.19
type ManifestStorage = string
const (
ManifestStorageGit ManifestStorage = "git"
)
type MaterialMetadata ¶
type MaterialMetadata struct {
ProgrammingLang string
LanguageRuntime string
BuildTool string
Executables []string
Profiles map[string]string // pipeline-stage, profile
LogDirs map[string]string //file, log pattern
EnvironmentVariables map[string]string
PropertiesConfig []PropertiesConfig
ExposeConfig []ServiceExposeConfig //a mocroservice can be exposed in multiple ways
MonitoringConfig MonitoringConfig
}
type MaterialOperations ¶
type MaterialOperations interface {
MaterialExists(material *GitMaterial) (bool, error)
SaveMaterial(material *GitMaterial) error
GenerateMaterialMetaData(material *GitMaterial) (*MaterialMetadata, error)
ValidateMaterialMetaData(material *GitMaterial, metadata *MaterialMetadata) (bool, error)
SaveMaterialMetaData(metadata *MaterialMetadata) error
}
type MonitoringConfig ¶
type PackagingConfig ¶
type PackagingConfig struct {
}
tag git build binary push binary to artifact store build docker image push docker image docker args
type PatchAction ¶
type PatchAction int
-------------------
const ( CREATE PatchAction = iota UPDATE_SOURCE //update value of SourceTypeConfig DELETE //delete this pipeline )
func (PatchAction) String ¶
func (a PatchAction) String() string
type PayloadOptionObject ¶ added in v0.6.9
type Pipeline ¶
type Pipeline struct {
Environment Environment
}
type PipelineCreateResponse ¶
type PropertiesConfig ¶
type ResponseDescriptionSchemaObject ¶ added in v0.6.9
type ResponseDescriptionSchemaObject struct {
Description string `json:"description,omitempty"`
ExampleValue ExampleValueDto `json:"exampleValue,omitempty"`
Schema map[string]interface{} `json:"schema,omitempty"`
}
type ResponseSchemaObject ¶ added in v0.6.9
type ResponseSchemaObject struct {
Description ResponseDescriptionSchemaObject `json:"description"`
Code string `json:"code"`
}
type SchemaObject ¶ added in v0.6.9
type SecretList ¶ added in v0.6.26
type SecretList struct {
ConfigData []*ConfigData `json:"secrets"`
}
func (SecretList) GetTransformedDataForSecret ¶ added in v0.6.26
func (SecretList) GetTransformedDataForSecret(data string, mode util.SecretTransformMode) (string, error)
type ServiceExposeConfig ¶
type SourceType ¶
type SourceType string
type SourceTypeConfig ¶
type SourceTypeConfig struct {
Type constants.SourceType `json:"type,omitempty" validate:"oneof=SOURCE_TYPE_BRANCH_FIXED SOURCE_TYPE_BRANCH_REGEX SOURCE_TYPE_TAG_ANY WEBHOOK"`
Value string `json:"value,omitempty" `
Regex string `json:"regex"`
}
type Strategy ¶
type Strategy struct {
DeploymentTemplate chartRepoRepository.DeploymentStrategy `json:"deploymentTemplate,omitempty"` //
Config json.RawMessage `json:"config,omitempty" validate:"string"`
Default bool `json:"default"`
}
type ThirdPartyMonitoringConfig ¶
type ThirdPartyMonitoringConfig struct {
}
type TriggerViewCiConfig ¶ added in v0.6.17
type TriggerViewCiConfig struct {
CiGitMaterialId int `json:"ciGitConfiguredId"`
CiPipelines []*CiPipeline `json:"ciPipelines,omitempty" validate:"dive"` //a pipeline will be built for each ciMaterial
Materials []Material `json:"materials"`
}
type UpdateMaterialDTO ¶
type UpdateMaterialDTO struct {
AppId int `json:"appId" validate:"number"`
Material *GitMaterial `json:"material" validate:"dive,min=1"`
UserId int32 `json:"-"` //not exposed to UI
}
type UpdateProjectBulkAppsRequest ¶ added in v0.6.0
type WorkflowCacheConfig ¶ added in v1.2.1
type WorkflowCacheConfig struct {
Type common.WorkflowCacheConfigType `json:"type"`
Value bool `json:"value"`
GlobalValue bool `json:"globalValue"`
}