Documentation
¶
Index ¶
- Constants
- Variables
- func AddTemplatesForGlobalSecretsInWorkflowTemplate(globalCmCsConfigs []*bean.GlobalCMCSDto, steps *[]argoWfApiV1.ParallelSteps, ...) error
- func CheckIfReTriggerRequired(status, message, workflowRunnerStatus string) bool
- func ExtractVolumes(configMaps []apiBean.ConfigSecretMap, secrets []apiBean.ConfigSecretMap) []k8sApiV1.Volume
- func GetClientInstance(config *rest.Config, namespace string) (argoWfClientV1.WorkflowInterface, error)
- func GetFromGlobalCmCsDtos(globalCmCsConfigs []*bean.GlobalCMCSDto) ([]apiBean.ConfigSecretMap, []apiBean.ConfigSecretMap, error)
- type ArgoWorkflowExecutor
- type ArgoWorkflowExecutorImpl
- func (impl *ArgoWorkflowExecutorImpl) ExecuteWorkflow(workflowTemplate bean.WorkflowTemplate) (*unstructured.UnstructuredList, error)
- func (impl *ArgoWorkflowExecutorImpl) GetWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) (*unstructured.UnstructuredList, error)
- func (impl *ArgoWorkflowExecutorImpl) GetWorkflowStatus(workflowName string, namespace string, clusterConfig *rest.Config) (*types.WorkflowStatus, error)
- func (impl *ArgoWorkflowExecutorImpl) TerminateDanglingWorkflow(workflowGenerateName string, namespace string, clusterConfig *rest.Config) error
- func (impl *ArgoWorkflowExecutorImpl) TerminateWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) error
- type SystemWorkflowExecutor
- type SystemWorkflowExecutorImpl
- func (impl *SystemWorkflowExecutorImpl) ExecuteWorkflow(workflowTemplate bean.WorkflowTemplate) (*unstructured.UnstructuredList, error)
- func (impl *SystemWorkflowExecutorImpl) GetWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) (*unstructured.UnstructuredList, error)
- func (impl *SystemWorkflowExecutorImpl) GetWorkflowStatus(workflowName string, namespace string, clusterConfig *rest.Config) (*types2.WorkflowStatus, error)
- func (impl *SystemWorkflowExecutorImpl) TerminateDanglingWorkflow(workflowGenerateName string, namespace string, clusterConfig *rest.Config) error
- func (impl *SystemWorkflowExecutorImpl) TerminateWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) error
- type WorkflowExecutor
Constants ¶
View Source
const ( STEP_NAME_REGEX = "create-env-%s-gb-%d" TEMPLATE_NAME_REGEX = "%s-gb-%d" WORKFLOW_MINIO_CRED = "workflow-minio-cred" CRED_ACCESS_KEY = "accessKey" CRED_SECRET_KEY = "secretKey" S3_ENDPOINT_URL = "s3.amazonaws.com" DEVTRON_WORKFLOW_LABEL_KEY = "devtron.ai/workflow-purpose" DEVTRON_WORKFLOW_LABEL_VALUE = "cd" WORKFLOW_GENERATE_NAME_REGEX = "%s-" RESOURCE_CREATE_ACTION = "create" )
View Source
const ( WorkflowJobBackoffLimit = 0 WorkflowJobFinalizer = "foregroundDeletion" )
Variables ¶
View Source
var AccessKeySelector = &k8sApiV1.SecretKeySelector{Key: CRED_ACCESS_KEY, LocalObjectReference: k8sApiV1.LocalObjectReference{Name: WORKFLOW_MINIO_CRED}}
View Source
var ArgoWorkflowOwnerRef = k8sMetaV1.OwnerReference{APIVersion: "argoproj.io/v1alpha1", Kind: "Workflow", Name: "{{workflow.name}}", UID: "{{workflow.uid}}", BlockOwnerDeletion: &[]bool{true}[0]}
View Source
var SecretKeySelector = &k8sApiV1.SecretKeySelector{Key: CRED_SECRET_KEY, LocalObjectReference: k8sApiV1.LocalObjectReference{Name: WORKFLOW_MINIO_CRED}}
Functions ¶
func AddTemplatesForGlobalSecretsInWorkflowTemplate ¶
func AddTemplatesForGlobalSecretsInWorkflowTemplate(globalCmCsConfigs []*bean.GlobalCMCSDto, steps *[]argoWfApiV1.ParallelSteps, volumes *[]k8sApiV1.Volume, templates *[]argoWfApiV1.Template) error
func ExtractVolumes ¶ added in v1.2.2
func ExtractVolumes(configMaps []apiBean.ConfigSecretMap, secrets []apiBean.ConfigSecretMap) []k8sApiV1.Volume
func GetClientInstance ¶
func GetClientInstance(config *rest.Config, namespace string) (argoWfClientV1.WorkflowInterface, error)
func GetFromGlobalCmCsDtos ¶
func GetFromGlobalCmCsDtos(globalCmCsConfigs []*bean.GlobalCMCSDto) ([]apiBean.ConfigSecretMap, []apiBean.ConfigSecretMap, error)
Types ¶
type ArgoWorkflowExecutor ¶
type ArgoWorkflowExecutor interface { WorkflowExecutor }
type ArgoWorkflowExecutorImpl ¶
type ArgoWorkflowExecutorImpl struct {
// contains filtered or unexported fields
}
func NewArgoWorkflowExecutorImpl ¶
func NewArgoWorkflowExecutorImpl(logger *zap.SugaredLogger) *ArgoWorkflowExecutorImpl
func (*ArgoWorkflowExecutorImpl) ExecuteWorkflow ¶
func (impl *ArgoWorkflowExecutorImpl) ExecuteWorkflow(workflowTemplate bean.WorkflowTemplate) (*unstructured.UnstructuredList, error)
func (*ArgoWorkflowExecutorImpl) GetWorkflow ¶ added in v0.6.26
func (impl *ArgoWorkflowExecutorImpl) GetWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) (*unstructured.UnstructuredList, error)
func (*ArgoWorkflowExecutorImpl) GetWorkflowStatus ¶ added in v0.6.26
func (impl *ArgoWorkflowExecutorImpl) GetWorkflowStatus(workflowName string, namespace string, clusterConfig *rest.Config) (*types.WorkflowStatus, error)
func (*ArgoWorkflowExecutorImpl) TerminateDanglingWorkflow ¶ added in v1.0.0
func (*ArgoWorkflowExecutorImpl) TerminateWorkflow ¶
type SystemWorkflowExecutor ¶
type SystemWorkflowExecutor interface { WorkflowExecutor }
type SystemWorkflowExecutorImpl ¶
type SystemWorkflowExecutorImpl struct {
// contains filtered or unexported fields
}
func NewSystemWorkflowExecutorImpl ¶
func NewSystemWorkflowExecutorImpl(logger *zap.SugaredLogger, k8sUtil *k8s.K8sServiceImpl) *SystemWorkflowExecutorImpl
func (*SystemWorkflowExecutorImpl) ExecuteWorkflow ¶
func (impl *SystemWorkflowExecutorImpl) ExecuteWorkflow(workflowTemplate bean.WorkflowTemplate) (*unstructured.UnstructuredList, error)
func (*SystemWorkflowExecutorImpl) GetWorkflow ¶ added in v0.6.26
func (impl *SystemWorkflowExecutorImpl) GetWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) (*unstructured.UnstructuredList, error)
func (*SystemWorkflowExecutorImpl) GetWorkflowStatus ¶ added in v0.6.26
func (impl *SystemWorkflowExecutorImpl) GetWorkflowStatus(workflowName string, namespace string, clusterConfig *rest.Config) (*types2.WorkflowStatus, error)
func (*SystemWorkflowExecutorImpl) TerminateDanglingWorkflow ¶ added in v1.0.0
func (*SystemWorkflowExecutorImpl) TerminateWorkflow ¶
type WorkflowExecutor ¶
type WorkflowExecutor interface { ExecuteWorkflow(workflowTemplate bean.WorkflowTemplate) (*unstructured.UnstructuredList, error) TerminateWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) error GetWorkflow(workflowName string, namespace string, clusterConfig *rest.Config) (*unstructured.UnstructuredList, error) GetWorkflowStatus(workflowName string, namespace string, clusterConfig *rest.Config) (*types.WorkflowStatus, error) TerminateDanglingWorkflow(workflowGenerateName string, namespace string, clusterConfig *rest.Config) error }
Click to show internal directories.
Click to hide internal directories.