gitops

package
v0.0.0-...-987a61a Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2022 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

View Source
const (
	GitOpsSecretName      = "template-cron-job-gitops-secret"
	DryrunRepoName        = "template-cron-job-sample-repo-dryrun-"
	DeleteRepoStage       = "Delete Repo"
	CommitOnRestStage     = "Commit On Rest"
	PushStage             = "Push"
	CloneStage            = "Clone"
	GetRepoUrlStage       = "Get Repo Url"
	CreateRepoStage       = "Create Repo"
	CloneHttp             = "Clone Http"
	CreateReadmeStage     = "Create Readme"
	GITHUB_PROVIDER       = "GITHUB"
	GITLAB_PROVIDER       = "GITLAB"
	BITBUCKET_PROVIDER    = "BITBUCKET_CLOUD"
	AZURE_DEVOPS_PROVIDER = "AZURE_DEVOPS"
	BITBUCKET_API_HOST    = "https://api.bitbucket.org/2.0/"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DetailedErrorGitOpsConfigResponse

type DetailedErrorGitOpsConfigResponse struct {
	SuccessfulStages []string          `json:"successfulStages"`
	StageErrorMap    map[string]string `json:"stageErrorMap"`
	ValidatedOn      time.Time         `json:"validatedOn"`
	DeleteRepoFailed bool              `json:"deleteRepoFailed"`
}

type GitOpsConfigService

type GitOpsConfigService interface {
	ValidateAndCreateGitOpsConfig(config *bean2.GitOpsConfigDto) (DetailedErrorGitOpsConfigResponse, error)
	ValidateAndUpdateGitOpsConfig(config *bean2.GitOpsConfigDto) (DetailedErrorGitOpsConfigResponse, error)
	GitOpsValidateDryRun(config *bean2.GitOpsConfigDto) DetailedErrorGitOpsConfigResponse
	CreateGitOpsConfig(config *bean2.GitOpsConfigDto) (*bean2.GitOpsConfigDto, error)
	UpdateGitOpsConfig(config *bean2.GitOpsConfigDto) error
	GetGitOpsConfigById(id int) (*bean2.GitOpsConfigDto, error)
	GetAllGitOpsConfig() ([]*bean2.GitOpsConfigDto, error)
	GetGitOpsConfigByProvider(provider string) (*bean2.GitOpsConfigDto, error)
	GetGitOpsConfigActive() (*bean2.GitOpsConfigDto, error)
}

type GitOpsConfigServiceImpl

type GitOpsConfigServiceImpl struct {
	K8sUtil *util.K8sUtil
	// contains filtered or unexported fields
}

func NewGitOpsConfigServiceImpl

func NewGitOpsConfigServiceImpl(Logger *zap.SugaredLogger, ciHandler pipeline.CiHandler,
	gitOpsRepository repository.GitOpsConfigRepository, K8sUtil *util.K8sUtil, aCDAuthConfig *util3.ACDAuthConfig,
	clusterService cluster.ClusterService, envService cluster.EnvironmentService, versionService argocdServer.VersionService,
	gitFactory *util.GitFactory, chartTemplateService util.ChartTemplateService) *GitOpsConfigServiceImpl

func (*GitOpsConfigServiceImpl) CreateGitOpsConfig

func (impl *GitOpsConfigServiceImpl) CreateGitOpsConfig(request *bean2.GitOpsConfigDto) (*bean2.GitOpsConfigDto, error)

func (*GitOpsConfigServiceImpl) GetAllGitOpsConfig

func (impl *GitOpsConfigServiceImpl) GetAllGitOpsConfig() ([]*bean2.GitOpsConfigDto, error)

func (*GitOpsConfigServiceImpl) GetGitOpsConfigActive

func (impl *GitOpsConfigServiceImpl) GetGitOpsConfigActive() (*bean2.GitOpsConfigDto, error)

func (*GitOpsConfigServiceImpl) GetGitOpsConfigById

func (impl *GitOpsConfigServiceImpl) GetGitOpsConfigById(id int) (*bean2.GitOpsConfigDto, error)

func (*GitOpsConfigServiceImpl) GetGitOpsConfigByProvider

func (impl *GitOpsConfigServiceImpl) GetGitOpsConfigByProvider(provider string) (*bean2.GitOpsConfigDto, error)

func (*GitOpsConfigServiceImpl) GitOpsValidateDryRun

func (*GitOpsConfigServiceImpl) UpdateGitOpsConfig

func (impl *GitOpsConfigServiceImpl) UpdateGitOpsConfig(request *bean2.GitOpsConfigDto) error

func (*GitOpsConfigServiceImpl) ValidateAndCreateGitOpsConfig

func (impl *GitOpsConfigServiceImpl) ValidateAndCreateGitOpsConfig(config *bean2.GitOpsConfigDto) (DetailedErrorGitOpsConfigResponse, error)

func (*GitOpsConfigServiceImpl) ValidateAndUpdateGitOpsConfig

func (impl *GitOpsConfigServiceImpl) ValidateAndUpdateGitOpsConfig(config *bean2.GitOpsConfigDto) (DetailedErrorGitOpsConfigResponse, error)

type KeyDto

type KeyDto struct {
	Name string `json:"name,omitempty"`
	Key  string `json:"key,omitempty"`
}

type RepositoryCredentialsDto

type RepositoryCredentialsDto struct {
	Url            string  `json:"url,omitempty"`
	UsernameSecret *KeyDto `json:"usernameSecret,omitempty"`
	PasswordSecret *KeyDto `json:"passwordSecret,omitempty"`
}

Jump to

Keyboard shortcuts

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