appstore

package
v1.2.8 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2021 License: Apache-2.0 Imports: 42 Imported by: 0

Documentation

Index

Constants

View Source
const BULK_APPSTORE_DEPLOY_DURABLE = "ORCHESTRATOR.APP-STORE.BULK-DEPLOY.DURABLE-1"
View Source
const BULK_APPSTORE_DEPLOY_GROUP = "ORCHESTRATOR.APP-STORE.BULK-DEPLOY-GROUP-1"
View Source
const BULK_APPSTORE_DEPLOY_TOPIC = "ORCHESTRATOR.APP-STORE.BULK-DEPLOY"
View Source
const CLUSTER_COMPONENT_DIR_PATH string = "/cluster/component"
View Source
const DEFAULT_ENVIRONMENT_OR_NAMESPACE_OR_PROJECT string = "devtron"
View Source
const REFERENCE_TYPE_DEFAULT string = "DEFAULT"
View Source
const REFERENCE_TYPE_DEPLOYED string = "DEPLOYED"
View Source
const REFERENCE_TYPE_EXISTING string = "EXISTING"
View Source
const REFERENCE_TYPE_TEMPLATE string = "TEMPLATE"

Variables

View Source
var CHART_PROXY_TEMPLATE = "reference-chart-proxy"
View Source
var REQUIREMENTS_YAML_FILE = "requirements.yaml"
View Source
var VALUES_YAML_FILE = "values.yaml"

Functions

This section is empty.

Types

type AcdConfigMapRepositoriesDto

type AcdConfigMapRepositoriesDto struct {
	Type           string  `json:"type,omitempty"`
	Name           string  `json:"name,omitempty"`
	Url            string  `json:"url,omitempty"`
	UsernameSecret *KeyDto `json:"usernameSecret,omitempty"`
	PasswordSecret *KeyDto `json:"passwordSecret,omitempty"`
	CaSecret       *KeyDto `json:"caSecret,omitempty"`
	CertSecret     *KeyDto `json:"certSecret,omitempty"`
	KeySecret      *KeyDto `json:"keySecret,omitempty"`
}

type AppNames

type AppNames struct {
	Name          string `json:"name,omitempty"`
	Exists        bool   `json:"exists"`
	SuggestedName string `json:"suggestedName,omitempty"`
}

type AppSotoreVersionDTOWrapper

type AppSotoreVersionDTOWrapper struct {
	Values []*AppStoreVersionValuesCategoryWiseDTO `json:"values"`
}

type AppStoreApplication

type AppStoreApplication struct {
	Id                          int                                   `json:"id"`
	Name                        string                                `json:"name"`
	ChartRepoId                 int                                   `json:"chartRepoId"`
	Active                      bool                                  `json:"active"`
	ChartGitLocation            string                                `json:"chartGitLocation"`
	CreatedOn                   time.Time                             `json:"createdOn"`
	UpdatedOn                   time.Time                             `json:"updatedOn"`
	AppStoreApplicationVersions []*AppStoreApplicationVersionResponse `json:"appStoreApplicationVersions"`
}

type AppStoreApplicationVersionResponse

type AppStoreApplicationVersionResponse struct {
	Id                      int       `json:"id"`
	Version                 string    `json:"version"`
	AppVersion              string    `json:"appVersion"`
	Created                 time.Time `json:"created"`
	Deprecated              bool      `json:"deprecated"`
	Description             string    `json:"description"`
	Digest                  string    `json:"digest"`
	Icon                    string    `json:"icon"`
	Name                    string    `json:"name"`
	ChartName               string    `json:"chartName"`
	AppStoreApplicationName string    `json:"appStoreApplicationName"`
	Home                    string    `json:"home"`
	Source                  string    `json:"source"`
	ValuesYaml              string    `json:"valuesYaml"`
	ChartYaml               string    `json:"chartYaml"`
	AppStoreId              int       `json:"appStoreId"`
	Latest                  bool      `json:"latest"`
	CreatedOn               time.Time `json:"createdOn"`
	RawValues               string    `json:"rawValues"`
	Readme                  string    `json:"readme"`
	UpdatedOn               time.Time `json:"updatedOn"`
	IsChartRepoActive       bool      `json:"isChartRepoActive"`
}

type AppStoreService

type AppStoreService interface {
	FindAllApps(filter *appstore.AppStoreFilter) ([]appstore.AppStoreWithVersion, error)
	FindChartDetailsById(id int) (AppStoreApplicationVersionResponse, error)
	FindChartVersionsByAppStoreId(appStoreId int) ([]AppStoreVersionsResponse, error)
	FindAppDetailsForAppstoreApplication(installedAppId, envId int) (bean.AppDetailContainer, error)
	GetReadMeByAppStoreApplicationVersionId(id int) (*ReadmeRes, error)

	SearchAppStoreChartByName(chartName string) ([]*appstore.ChartRepoSearch, error)
	CreateChartRepo(request *ChartRepoDto) (*chartConfig.ChartRepo, error)
	UpdateChartRepo(request *ChartRepoDto) (*chartConfig.ChartRepo, error)
	GetChartRepoById(id int) (*ChartRepoDto, error)
	GetChartRepoList() ([]*ChartRepoDto, error)
}

type AppStoreServiceImpl

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

func NewAppStoreServiceImpl

func NewAppStoreServiceImpl(logger *zap.SugaredLogger, appStoreRepository appstore.AppStoreRepository,
	appStoreApplicationRepository appstore.AppStoreApplicationVersionRepository, installedAppRepository appstore.InstalledAppRepository,
	userService user.UserService, repoRepository chartConfig.ChartRepoRepository, K8sUtil *util.K8sUtil,
	clusterService cluster.ClusterService, envService cluster.EnvironmentService,
	versionService argocdServer.VersionService, aCDAuthConfig *user.ACDAuthConfig) *AppStoreServiceImpl

func (*AppStoreServiceImpl) CreateChartRepo

func (impl *AppStoreServiceImpl) CreateChartRepo(request *ChartRepoDto) (*chartConfig.ChartRepo, error)

func (*AppStoreServiceImpl) FindAllApps

func (*AppStoreServiceImpl) FindAppDetailsForAppstoreApplication

func (impl *AppStoreServiceImpl) FindAppDetailsForAppstoreApplication(installedAppId, envId int) (bean.AppDetailContainer, error)

func (*AppStoreServiceImpl) FindChartDetailsById

func (impl *AppStoreServiceImpl) FindChartDetailsById(id int) (AppStoreApplicationVersionResponse, error)

func (*AppStoreServiceImpl) FindChartVersionsByAppStoreId

func (impl *AppStoreServiceImpl) FindChartVersionsByAppStoreId(appStoreId int) ([]AppStoreVersionsResponse, error)

func (*AppStoreServiceImpl) GetChartRepoById

func (impl *AppStoreServiceImpl) GetChartRepoById(id int) (*ChartRepoDto, error)

func (*AppStoreServiceImpl) GetChartRepoList

func (impl *AppStoreServiceImpl) GetChartRepoList() ([]*ChartRepoDto, error)

func (*AppStoreServiceImpl) GetReadMeByAppStoreApplicationVersionId

func (impl *AppStoreServiceImpl) GetReadMeByAppStoreApplicationVersionId(id int) (*ReadmeRes, error)

func (*AppStoreServiceImpl) SearchAppStoreChartByName

func (impl *AppStoreServiceImpl) SearchAppStoreChartByName(chartName string) ([]*appstore.ChartRepoSearch, error)

func (*AppStoreServiceImpl) UpdateChartRepo

func (impl *AppStoreServiceImpl) UpdateChartRepo(request *ChartRepoDto) (*chartConfig.ChartRepo, error)

type AppStoreValuesService

type AppStoreValuesService interface {
	CreateAppStoreVersionValues(model *AppStoreVersionValuesDTO) (*AppStoreVersionValuesDTO, error)
	UpdateAppStoreVersionValues(model *AppStoreVersionValuesDTO) (*AppStoreVersionValuesDTO, error)
	FindValuesByIdAndKind(referenceId int, kind string) (*AppStoreVersionValuesDTO, error)
	DeleteAppStoreVersionValues(appStoreValueId int) (bool, error)

	FindValuesByAppStoreId(appStoreId int, installedAppVersionId int) (*AppSotoreVersionDTOWrapper, error)
	FindValuesByAppStoreIdAndReferenceType(appStoreVersionId int, referenceType string) ([]*AppStoreVersionValuesDTO, error)
	GetSelectedChartMetaData(req *ChartMetaDataRequestWrapper) ([]*ChartMetaDataResponse, error)
}

type AppStoreValuesServiceImpl

type AppStoreValuesServiceImpl struct {
	// contains filtered or unexported fields
}

func NewAppStoreValuesServiceImpl

func NewAppStoreValuesServiceImpl(logger *zap.SugaredLogger, appStoreRepository appstore.AppStoreRepository,
	appStoreApplicationRepository appstore.AppStoreApplicationVersionRepository, installedAppRepository appstore.InstalledAppRepository,
	userService user.UserService, appStoreVersionValuesRepository appstore.AppStoreVersionValuesRepository,
	mergeUtil util.MergeUtil) *AppStoreValuesServiceImpl

func (AppStoreValuesServiceImpl) CreateAppStoreVersionValues

func (impl AppStoreValuesServiceImpl) CreateAppStoreVersionValues(request *AppStoreVersionValuesDTO) (*AppStoreVersionValuesDTO, error)

func (AppStoreValuesServiceImpl) DeleteAppStoreVersionValues

func (impl AppStoreValuesServiceImpl) DeleteAppStoreVersionValues(appStoreValueId int) (bool, error)

func (AppStoreValuesServiceImpl) FindValuesByAppStoreId

func (impl AppStoreValuesServiceImpl) FindValuesByAppStoreId(appStoreId int, installedAppVersionId int) (*AppSotoreVersionDTOWrapper, error)

func (AppStoreValuesServiceImpl) FindValuesByAppStoreIdAndReferenceType

func (impl AppStoreValuesServiceImpl) FindValuesByAppStoreIdAndReferenceType(appStoreId int, referenceType string) ([]*AppStoreVersionValuesDTO, error)

func (AppStoreValuesServiceImpl) FindValuesByIdAndKind

func (impl AppStoreValuesServiceImpl) FindValuesByIdAndKind(referenceId int, kind string) (*AppStoreVersionValuesDTO, error)

func (AppStoreValuesServiceImpl) GetSelectedChartMetaData

func (impl AppStoreValuesServiceImpl) GetSelectedChartMetaData(req *ChartMetaDataRequestWrapper) ([]*ChartMetaDataResponse, error)

func (AppStoreValuesServiceImpl) UpdateAppStoreVersionValues

func (impl AppStoreValuesServiceImpl) UpdateAppStoreVersionValues(request *AppStoreVersionValuesDTO) (*AppStoreVersionValuesDTO, error)

type AppStoreVersionValuesCategoryWiseDTO

type AppStoreVersionValuesCategoryWiseDTO struct {
	Values []*AppStoreVersionValuesDTO `json:"values"`
	Kind   string                      `json:"kind"`
}

type AppStoreVersionValuesDTO

type AppStoreVersionValuesDTO struct {
	Id                int    `json:"id,omitempty"`
	AppStoreVersionId int    `json:"appStoreVersionId,omitempty,notnull"`
	Name              string `json:"name,omitempty"`
	Values            string `json:"values,omitempty"` //yaml format user value
	ChartVersion      string `json:"chartVersion,omitempty"`
	EnvironmentName   string `json:"environmentName,omitempty"`
	UserId            int32  `json:"-"`
}

type AppStoreVersionsResponse

type AppStoreVersionsResponse struct {
	Version string `json:"version"`
	Id      int    `json:"id"`
}

type ChartComponent

type ChartComponent struct {
	Name   string `json:"name"`
	Values string `json:"values"`
}

type ChartComponents

type ChartComponents struct {
	ChartComponent []*ChartComponent `json:"charts"`
}

type ChartGroupBean

type ChartGroupBean struct {
	Name               string                 `json:"name,omitempty" validate:"name-component,max=200"`
	Description        string                 `json:"description,omitempty"`
	Id                 int                    `json:"id,omitempty"`
	ChartGroupEntries  []*ChartGroupEntryBean `json:"chartGroupEntries,omitempty"`
	InstalledChartData []*InstalledChartData  `json:"installedChartData,omitempty"`
	UserId             int32                  `json:"-"`
}

type ChartGroupEntryBean

type ChartGroupEntryBean struct {
	Id                           int            `json:"id,omitempty"`
	AppStoreValuesVersionId      int            `json:"appStoreValuesVersionId,omitempty"` //AppStoreVersionValuesId
	AppStoreValuesVersionName    string         `json:"appStoreValuesVersionName,omitempty"`
	AppStoreValuesChartVersion   string         `json:"appStoreValuesChartVersion,omitempty"`   //chart version corresponding to values
	AppStoreApplicationVersionId int            `json:"appStoreApplicationVersionId,omitempty"` //AppStoreApplicationVersionId
	ChartMetaData                *ChartMetaData `json:"chartMetaData,omitempty"`
	ReferenceType                string         `json:"referenceType, omitempty"`
}

type ChartGroupInstallAppRes

type ChartGroupInstallAppRes struct {
}

type ChartGroupInstallChartRequest

type ChartGroupInstallChartRequest struct {
	AppName                 string `json:"appName,omitempty"  validate:"name-component,max=100" `
	EnvironmentId           int    `json:"environmentId,omitempty" validate:"required,number" `
	AppStoreVersion         int    `json:"appStoreVersion,omitempty,notnull" validate:"required,number" `
	ValuesOverrideYaml      string `json:"valuesOverrideYaml,omitempty"` //optional
	ReferenceValueId        int    `json:"referenceValueId, omitempty" validate:"required,number"`
	ReferenceValueKind      string `json:"referenceValueKind, omitempty" validate:"oneof=DEFAULT TEMPLATE DEPLOYED"`
	ChartGroupEntryId       int    `json:"chartGroupEntryId"` //optional
	DefaultClusterComponent bool   `json:"-"`
}

type ChartGroupInstallRequest

type ChartGroupInstallRequest struct {
	ProjectId                     int                              `json:"projectId"  validate:"required,number"`
	ChartGroupInstallChartRequest []*ChartGroupInstallChartRequest `json:"charts" validate:"dive,required"`
	ChartGroupId                  int                              `json:"chartGroupId"` //optional
	UserId                        int32                            `json:"-"`
}

/ bean for v2

type ChartGroupList

type ChartGroupList struct {
	Groups []*ChartGroupBean `json:"groups,omitempty"`
}

type ChartGroupService

type ChartGroupService interface {
	CreateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)
	UpdateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)
	SaveChartGroupEntries(req *ChartGroupBean) (*ChartGroupBean, error)
	GetChartGroupWithChartMetaData(chartGroupId int) (*ChartGroupBean, error)
	ChartGroupList(max int) (*ChartGroupList, error)
	GetChartGroupWithInstallationDetail(chartGroupId int) (*ChartGroupBean, error)
	ChartGroupListMin(max int) ([]*ChartGroupBean, error)
}

type ChartGroupServiceImpl

type ChartGroupServiceImpl struct {
	Logger *zap.SugaredLogger
	// contains filtered or unexported fields
}

func NewChartGroupServiceImpl

func NewChartGroupServiceImpl(chartGroupEntriesRepository chartGroup.ChartGroupEntriesRepository,
	chartGroupRepository chartGroup.ChartGroupReposotory,
	Logger *zap.SugaredLogger, chartGroupDeploymentRepository chartGroup.ChartGroupDeploymentRepository,
	installedAppRepository appstore.InstalledAppRepository, appStoreVersionValuesRepository appstore.AppStoreVersionValuesRepository) *ChartGroupServiceImpl

func (*ChartGroupServiceImpl) ChartGroupList

func (impl *ChartGroupServiceImpl) ChartGroupList(max int) (*ChartGroupList, error)

func (*ChartGroupServiceImpl) ChartGroupListMin

func (impl *ChartGroupServiceImpl) ChartGroupListMin(max int) ([]*ChartGroupBean, error)

func (*ChartGroupServiceImpl) CreateChartGroup

func (impl *ChartGroupServiceImpl) CreateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) GetChartGroupWithChartMetaData

func (impl *ChartGroupServiceImpl) GetChartGroupWithChartMetaData(chartGroupId int) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) GetChartGroupWithInstallationDetail

func (impl *ChartGroupServiceImpl) GetChartGroupWithInstallationDetail(chartGroupId int) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) SaveChartGroupEntries

func (impl *ChartGroupServiceImpl) SaveChartGroupEntries(req *ChartGroupBean) (*ChartGroupBean, error)

func (*ChartGroupServiceImpl) UpdateChartGroup

func (impl *ChartGroupServiceImpl) UpdateChartGroup(req *ChartGroupBean) (*ChartGroupBean, error)

type ChartMetaData

type ChartMetaData struct {
	ChartName                  string `json:"chartName,omitempty"`
	ChartRepoName              string `json:"chartRepoName,omitempty"`
	Icon                       string `json:"icon,omitempty"`
	AppStoreId                 int    `json:"appStoreId"`
	AppStoreApplicationVersion string `json:"appStoreApplicationVersion"`
	EnvironmentName            string `json:"environmentName,omitempty"`
	EnvironmentId              int    `json:"environmentId,omitempty"` //FIXME REMOVE THIS ATTRIBUTE AFTER REMOVING ENVORONMENTID FROM GETINSTALLEDAPPCALL
	IsChartRepoActive          bool   `json:"isChartRepoActive"`
}

type ChartMetaDataRequest

type ChartMetaDataRequest struct {
	Kind  string `json:"kind"`
	Value int    `json:"value"`
}
func (impl AppStoreValuesServiceImpl) adaptorForValuesCategoryWise(values *appstore.AppStoreVersionValues) (val *AppStoreVersionValuesCategoryWiseDTO) {
	version := ""
	if values.AppStoreApplicationVersion != nil {
		version = values.AppStoreApplicationVersion.Version
	}

	valDto:= &AppStoreVersionValuesDTO{
		Name:              values.Name,
		Id:                values.Id,
		Values:            values.ValuesYaml,
		ChartVersion:      version,
		AppStoreVersionId: values.AppStoreApplicationVersionId,
	}
	val = &AppStoreVersionValuesCategoryWiseDTO{
		Values:valDto
	}
	return val
}

type ChartMetaDataRequestWrapper

type ChartMetaDataRequestWrapper struct {
	Values []*ChartMetaDataRequest `json:"values"`
}

type ChartMetaDataResponse

type ChartMetaDataResponse struct {
	//version, name, rep, char val name,
	ChartName                    string `json:"chartName"`
	ChartRepoName                string `json:"chartRepoName"`
	AppStoreApplicationVersionId int    `json:"appStoreApplicationVersionId"`
	Icon                         string `json:"icon"`
	Kind                         string `json:"kind"`
}

type ChartRepoDto

type ChartRepoDto struct {
	Id          int                 `json:"id,omitempty" validate:"number"`
	Name        string              `json:"name,omitempty" validate:"required"`
	Url         string              `json:"url,omitempty"`
	UserName    string              `json:"userName,omitempty"`
	Password    string              `json:"password,omitempty"`
	SshKey      string              `json:"sshKey,omitempty"`
	AccessToken string              `json:"accessToken,omitempty"`
	AuthMode    repository.AuthMode `json:"authMode,omitempty" validate:"required"`
	Active      bool                `json:"active"`
	Default     bool                `json:"default"`
	UserId      int32               `json:"-"`
}

type ConfigMapDataDto

type ConfigMapDataDto struct {
	HelmRepositories string `json:"helm.repositories,omitempty"`
	Repositories     string `json:"repositories,omitempty"`
}

type Dependencies

type Dependencies struct {
	Dependencies []Dependency `json:"dependencies"`
}

type Dependency

type Dependency struct {
	Name       string `json:"name"`
	Version    string `json:"version"`
	Repository string `json:"repository"`
}

type DeployPayload

type DeployPayload struct {
	InstalledAppVersionId int
}

type HelmRepositoriesData

type HelmRepositoriesData struct {
	Name string `json:"name,omitempty"`
	Url  string `json:"url,omitempty"`
}

type InstallAppVersionDTO

type InstallAppVersionDTO struct {
	Id                      int                               `json:"id,omitempty"`
	AppId                   int                               `json:"appId,omitempty"`
	AppName                 string                            `json:"appName,omitempty"`
	TeamId                  int                               `json:"teamId,omitempty"`
	EnvironmentId           int                               `json:"environmentId,omitempty"`
	InstalledAppId          int                               `json:"installedAppId,omitempty,notnull"`
	InstalledAppVersionId   int                               `json:"installedAppVersionId,omitempty,notnull"`
	AppStoreVersion         int                               `json:"appStoreVersion,omitempty,notnull"`
	ValuesOverrideYaml      string                            `json:"valuesOverrideYaml,omitempty"`
	Readme                  string                            `json:"readme,omitempty"`
	UserId                  int32                             `json:"-"`
	ReferenceValueId        int                               `json:"referenceValueId, omitempty" validate:"required,number"`
	ReferenceValueKind      string                            `json:"referenceValueKind, omitempty" validate:"oneof=DEFAULT TEMPLATE DEPLOYED EXISTING"`
	ACDAppName              string                            `json:"-"`
	Environment             *cluster.Environment              `json:"-"`
	ChartGroupEntryId       int                               `json:"-"`
	DefaultClusterComponent bool                              `json:"-"`
	Status                  appstore.AppstoreDeploymentStatus `json:"-"`
	AppStoreId              int                               `json:"appStoreId"`
	AppStoreName            string                            `json:"appStoreName"`
	Deprecated              bool                              `json:"deprecated"`
}

v1

type InstalledAppService

type InstalledAppService interface {
	UpdateInstalledApp(ctx context.Context, installAppVersionRequest *InstallAppVersionDTO) (*InstallAppVersionDTO, error)
	GetInstalledApp(id int) (*InstallAppVersionDTO, error)
	GetInstalledAppVersion(id int) (*InstallAppVersionDTO, error)
	GetAll(environments []int) ([]InstalledAppsResponse, error)
	GetAllInstalledAppsByAppStoreId(w http.ResponseWriter, r *http.Request, token string, appStoreId int) ([]InstalledAppsResponse, error)
	DeleteInstalledApp(ctx context.Context, installAppVersionRequest *InstallAppVersionDTO) (*InstallAppVersionDTO, error)

	DeployBulk(chartGroupInstallRequest *ChartGroupInstallRequest) (*ChartGroupInstallAppRes, error)

	CreateInstalledAppV2(installAppVersionRequest *InstallAppVersionDTO, ctx context.Context) (*InstallAppVersionDTO, error)
	AppStoreDeployOperationGIT(installAppVersionRequest *InstallAppVersionDTO) (*InstallAppVersionDTO, *util.ChartGitAttribute, error)
	AppStoreDeployOperationACD(installAppVersionRequest *InstallAppVersionDTO, chartGitAttr *util.ChartGitAttribute, ctx context.Context) (*InstallAppVersionDTO, error)
	AppStoreDeployOperationDB(installAppVersionRequest *InstallAppVersionDTO, tx *pg.Tx) (*InstallAppVersionDTO, error)

	AppStoreDeployOperationStatusUpdate(installAppId int, status appstore.AppstoreDeploymentStatus) (bool, error)
	CheckAppExists(appNames []*AppNames) ([]*AppNames, error)

	DeployDefaultChartOnCluster(bean *cluster2.ClusterBean, userId int32) (bool, error)
	IsChartRepoActive(appStoreVersionId int) (bool, error)
	DeployDefaultComponent(chartGroupInstallRequest *ChartGroupInstallRequest) (*ChartGroupInstallAppRes, error)
	// contains filtered or unexported methods
}

type InstalledAppServiceImpl

type InstalledAppServiceImpl struct {
	ArgoK8sClient argocdServer.ArgoK8sClient
	// contains filtered or unexported fields
}

func NewInstalledAppServiceImpl

func NewInstalledAppServiceImpl(chartRepository chartConfig.ChartRepository,
	logger *zap.SugaredLogger,
	repoRepository chartConfig.ChartRepoRepository,
	mergeUtil util.MergeUtil,
	pipelineConfigRepository chartConfig.PipelineConfigRepository,
	configMapRepository chartConfig.ConfigMapRepository,
	installedAppRepository appstore.InstalledAppRepository,
	chartTemplateService util.ChartTemplateService, refChartDir RefChartProxyDir,
	repositoryService repository.ServiceClient,
	appStoreApplicationVersionRepository appstore.AppStoreApplicationVersionRepository,
	environmentRepository cluster.EnvironmentRepository, teamRepository team.TeamRepository,
	appRepository pipelineConfig.AppRepository,
	acdClient application2.ServiceClient,
	appStoreValuesService AppStoreValuesService,
	pubsubClient *pubsub.PubSubClient,
	tokenCache *user.TokenCache,
	chartGroupDeploymentRepository chartGroup.ChartGroupDeploymentRepository,
	envService cluster2.EnvironmentService,
	clusterInstalledAppsRepository appstore.ClusterInstalledAppsRepository,
	argoK8sClient argocdServer.ArgoK8sClient,
	gitFactory *util.GitFactory) (*InstalledAppServiceImpl, error)

func (InstalledAppServiceImpl) AppStoreDeployOperationACD

func (impl InstalledAppServiceImpl) AppStoreDeployOperationACD(installAppVersionRequest *InstallAppVersionDTO, chartGitAttr *util.ChartGitAttribute, ctx context.Context) (*InstallAppVersionDTO, error)

func (InstalledAppServiceImpl) AppStoreDeployOperationDB

func (impl InstalledAppServiceImpl) AppStoreDeployOperationDB(installAppVersionRequest *InstallAppVersionDTO, tx *pg.Tx) (*InstallAppVersionDTO, error)

func (InstalledAppServiceImpl) AppStoreDeployOperationGIT

func (impl InstalledAppServiceImpl) AppStoreDeployOperationGIT(installAppVersionRequest *InstallAppVersionDTO) (*InstallAppVersionDTO, *util.ChartGitAttribute, error)

func (InstalledAppServiceImpl) AppStoreDeployOperationStatusUpdate

func (impl InstalledAppServiceImpl) AppStoreDeployOperationStatusUpdate(installAppId int, status appstore.AppstoreDeploymentStatus) (bool, error)

func (InstalledAppServiceImpl) CheckAppExists

func (impl InstalledAppServiceImpl) CheckAppExists(appNames []*AppNames) ([]*AppNames, error)

func (InstalledAppServiceImpl) CreateInstalledAppV2

func (impl InstalledAppServiceImpl) CreateInstalledAppV2(installAppVersionRequest *InstallAppVersionDTO, ctx context.Context) (*InstallAppVersionDTO, error)

func (InstalledAppServiceImpl) DeleteInstalledApp

func (impl InstalledAppServiceImpl) DeleteInstalledApp(ctx context.Context, installAppVersionRequest *InstallAppVersionDTO) (*InstallAppVersionDTO, error)

func (InstalledAppServiceImpl) DeployBulk

func (impl InstalledAppServiceImpl) DeployBulk(chartGroupInstallRequest *ChartGroupInstallRequest) (*ChartGroupInstallAppRes, error)

func (*InstalledAppServiceImpl) DeployDefaultChartOnCluster

func (impl *InstalledAppServiceImpl) DeployDefaultChartOnCluster(bean *cluster2.ClusterBean, userId int32) (bool, error)

func (InstalledAppServiceImpl) DeployDefaultComponent

func (impl InstalledAppServiceImpl) DeployDefaultComponent(chartGroupInstallRequest *ChartGroupInstallRequest) (*ChartGroupInstallAppRes, error)

func (InstalledAppServiceImpl) GetAll

func (impl InstalledAppServiceImpl) GetAll(environments []int) ([]InstalledAppsResponse, error)

func (InstalledAppServiceImpl) GetAllInstalledAppsByAppStoreId

func (impl InstalledAppServiceImpl) GetAllInstalledAppsByAppStoreId(w http.ResponseWriter, r *http.Request, token string, appStoreId int) ([]InstalledAppsResponse, error)

TODO: Test ACD to get status

func (InstalledAppServiceImpl) GetInstalledApp

func (impl InstalledAppServiceImpl) GetInstalledApp(id int) (*InstallAppVersionDTO, error)

func (InstalledAppServiceImpl) GetInstalledAppVersion

func (impl InstalledAppServiceImpl) GetInstalledAppVersion(id int) (*InstallAppVersionDTO, error)

func (*InstalledAppServiceImpl) IsChartRepoActive

func (impl *InstalledAppServiceImpl) IsChartRepoActive(appStoreVersionId int) (bool, error)

func (*InstalledAppServiceImpl) Subscribe

func (impl *InstalledAppServiceImpl) Subscribe() error

func (InstalledAppServiceImpl) UpdateInstalledApp

func (impl InstalledAppServiceImpl) UpdateInstalledApp(ctx context.Context, installAppVersionRequest *InstallAppVersionDTO) (*InstallAppVersionDTO, error)

type InstalledAppsResponse

type InstalledAppsResponse struct {
	AppStoreApplicationName      string    `json:"appStoreApplicationName"`
	ChartName                    string    `json:"chartName"`
	Icon                         string    `json:"icon"`
	Status                       string    `json:"status"`
	AppName                      string    `json:"appName"`
	InstalledAppVersionId        int       `json:"installedAppVersionId"`
	AppStoreApplicationVersionId int       `json:"appStoreApplicationVersionId"`
	EnvironmentName              string    `json:"environmentName"`
	DeployedAt                   time.Time `json:"deployedAt"`
	DeployedBy                   string    `json:"deployedBy"`
	InstalledAppsId              int       `json:"installedAppId"`
	Readme                       string    `json:"readme"`
	EnvironmentId                int       `json:"environmentId"`
	Deprecated                   bool      `json:"deprecated"`
}

type InstalledChart

type InstalledChart struct {
	ChartMetaData
	InstalledAppId int `json:"installedAppId,omitempty"`
}

type InstalledChartData

type InstalledChartData struct {
	InstallationTime time.Time         `json:"installationTime,omitempty"`
	InstalledCharts  []*InstalledChart `json:"installedCharts,omitempty"`
}

type KeyDto

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

type ReadmeRes

type ReadmeRes struct {
	AppStoreApplicationVersionId int    `json:"appStoreApplicationVersionId"`
	Readme                       string `json:"readme"`
}

type RefChartProxyDir

type RefChartProxyDir string

/

type ValuesCategoryResponse

type ValuesCategoryResponse struct {
	ReferenceType      json.RawMessage      `json:"referenceType,omitempty"` //json format user value
	ValuesListCategory []ValuesListCategory `json:"valuesListCategory,omitempty"`
}

type ValuesListCategory

type ValuesListCategory struct {
	Id                int             `json:"id,omitempty"`
	AppStoreVersionId int             `json:"appStoreVersionId,omitempty,notnull"`
	ReferenceId       int             `json:"referenceId,omitempty,notnull"`
	Name              string          `json:"name,omitempty"`
	ValuesOverride    json.RawMessage `json:"valuesOverride,omitempty"` //json format user value
}

Jump to

Keyboard shortcuts

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