Documentation ¶
Index ¶
- Variables
- func GenerateManifests(ctx context.Context, appPath, repoRoot, revision string, ...) (*apiclient.ManifestResponse, error)
- func GetAppSourceType(ctx context.Context, source *v1alpha1.ApplicationSource, ...) (v1alpha1.ApplicationSourceType, error)
- func NewRepositoryLock() *repositoryLock
- type Chart
- type GenerateManifestOpt
- type Maintainer
- type ManifestResponsePromise
- type RepoServerInitConstants
- type Service
- func (s *Service) GenerateManifest(ctx context.Context, q *apiclient.ManifestRequest) (*apiclient.ManifestResponse, error)
- func (s *Service) GenerateManifestWithFiles(stream apiclient.RepoServerService_GenerateManifestWithFilesServer) error
- func (s *Service) GetAppDetails(ctx context.Context, q *apiclient.RepoServerAppDetailsQuery) (*apiclient.RepoAppDetailsResponse, error)
- func (s *Service) GetGitDirectories(_ context.Context, request *apiclient.GitDirectoriesRequest) (*apiclient.GitDirectoriesResponse, error)
- func (s *Service) GetGitFiles(_ context.Context, request *apiclient.GitFilesRequest) (*apiclient.GitFilesResponse, error)
- func (s *Service) GetHelmCharts(ctx context.Context, q *apiclient.HelmChartsRequest) (*apiclient.HelmChartsResponse, error)
- func (s *Service) GetRevisionChartDetails(ctx context.Context, q *apiclient.RepoServerRevisionChartDetailsRequest) (*v1alpha1.ChartDetails, error)
- func (s *Service) GetRevisionMetadata(ctx context.Context, q *apiclient.RepoServerRevisionMetadataRequest) (*v1alpha1.RevisionMetadata, error)
- func (s *Service) Init() error
- func (s *Service) ListApps(ctx context.Context, q *apiclient.ListAppsRequest) (*apiclient.AppList, error)
- func (s *Service) ListPlugins(ctx context.Context, _ *empty.Empty) (*apiclient.PluginList, error)
- func (s *Service) ListRefs(ctx context.Context, q *apiclient.ListRefsRequest) (*apiclient.Refs, error)
- func (s *Service) ResolveRevision(ctx context.Context, q *apiclient.ResolveRevisionRequest) (*apiclient.ResolveRevisionResponse, error)
- func (s *Service) TestRepository(ctx context.Context, q *apiclient.TestRepositoryRequest) (*apiclient.TestRepositoryResponse, error)
Constants ¶
This section is empty.
Variables ¶
var ErrExceededMaxCombinedManifestFileSize = errors.New("exceeded max combined manifest file size")
Functions ¶
func GenerateManifests ¶
func GenerateManifests(ctx context.Context, appPath, repoRoot, revision string, q *apiclient.ManifestRequest, isLocal bool, gitCredsStore git.CredsStore, maxCombinedManifestQuantity resource.Quantity, gitRepoPaths io.TempPaths, opts ...GenerateManifestOpt) (*apiclient.ManifestResponse, error)
GenerateManifests generates manifests from a path. Overrides are applied as a side effect on the given ApplicationSource.
func GetAppSourceType ¶
func GetAppSourceType(ctx context.Context, source *v1alpha1.ApplicationSource, appPath, repoPath, appName string, enableGenerateManifests map[string]bool, tarExcludedGlobs []string) (v1alpha1.ApplicationSourceType, error)
GetAppSourceType returns explicit application source type or examines a directory and determines its application source type
func NewRepositoryLock ¶
func NewRepositoryLock() *repositoryLock
Types ¶
type Chart ¶ added in v2.9.0
type Chart struct { Description string `yaml:"description,omitempty"` Home string `yaml:"home,omitempty"` Maintainers []Maintainer `yaml:"maintainers,omitempty"` }
Chart see: https://helm.sh/docs/topics/charts/ for more details
type GenerateManifestOpt ¶ added in v2.4.0
type GenerateManifestOpt func(*generateManifestOpt)
func WithCMPTarDoneChannel ¶ added in v2.4.0
func WithCMPTarDoneChannel(ch chan<- bool) GenerateManifestOpt
WithCMPTarDoneChannel defines the channel to be used to signalize when the tarball generation is concluded when generating manifests with the CMP server. This is used to unlock the git repo as soon as possible.
func WithCMPTarExcludedGlobs ¶ added in v2.4.4
func WithCMPTarExcludedGlobs(excludedGlobs []string) GenerateManifestOpt
WithCMPTarExcludedGlobs defines globs for files to filter out when streaming the tarball to a CMP sidecar.
type Maintainer ¶ added in v2.9.0
type ManifestResponsePromise ¶ added in v2.4.0
type ManifestResponsePromise struct {
// contains filtered or unexported fields
}
func NewManifestResponsePromise ¶ added in v2.4.0
func NewManifestResponsePromise(responseCh <-chan *apiclient.ManifestResponse, tarDoneCh <-chan bool, errCh chan error) *ManifestResponsePromise
type RepoServerInitConstants ¶
type RepoServerInitConstants struct { ParallelismLimit int64 PauseGenerationAfterFailedGenerationAttempts int PauseGenerationOnFailureForMinutes int PauseGenerationOnFailureForRequests int SubmoduleEnabled bool MaxCombinedDirectoryManifestsSize resource.Quantity CMPTarExcludedGlobs []string AllowOutOfBoundsSymlinks bool StreamedManifestMaxExtractedSize int64 StreamedManifestMaxTarSize int64 HelmManifestMaxExtractedSize int64 DisableHelmManifestMaxExtractedSize bool }
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service implements ManifestService interface
func NewService ¶
func NewService(metricsServer *metrics.MetricsServer, cache *cache.Cache, initConstants RepoServerInitConstants, resourceTracking argo.ResourceTracking, gitCredsStore git.CredsStore, rootDir string) *Service
NewService returns a new instance of the Manifest service
func (*Service) GenerateManifest ¶
func (s *Service) GenerateManifest(ctx context.Context, q *apiclient.ManifestRequest) (*apiclient.ManifestResponse, error)
func (*Service) GenerateManifestWithFiles ¶ added in v2.5.0
func (s *Service) GenerateManifestWithFiles(stream apiclient.RepoServerService_GenerateManifestWithFilesServer) error
func (*Service) GetAppDetails ¶
func (s *Service) GetAppDetails(ctx context.Context, q *apiclient.RepoServerAppDetailsQuery) (*apiclient.RepoAppDetailsResponse, error)
func (*Service) GetGitDirectories ¶ added in v2.8.0
func (s *Service) GetGitDirectories(_ context.Context, request *apiclient.GitDirectoriesRequest) (*apiclient.GitDirectoriesResponse, error)
func (*Service) GetGitFiles ¶ added in v2.8.0
func (s *Service) GetGitFiles(_ context.Context, request *apiclient.GitFilesRequest) (*apiclient.GitFilesResponse, error)
func (*Service) GetHelmCharts ¶
func (s *Service) GetHelmCharts(ctx context.Context, q *apiclient.HelmChartsRequest) (*apiclient.HelmChartsResponse, error)
func (*Service) GetRevisionChartDetails ¶ added in v2.8.0
func (s *Service) GetRevisionChartDetails(ctx context.Context, q *apiclient.RepoServerRevisionChartDetailsRequest) (*v1alpha1.ChartDetails, error)
GetRevisionChartDetails returns the helm chart details of a given version
func (*Service) GetRevisionMetadata ¶
func (s *Service) GetRevisionMetadata(ctx context.Context, q *apiclient.RepoServerRevisionMetadataRequest) (*v1alpha1.RevisionMetadata, error)
func (*Service) ListApps ¶
func (s *Service) ListApps(ctx context.Context, q *apiclient.ListAppsRequest) (*apiclient.AppList, error)
ListApps lists the contents of a GitHub repo
func (*Service) ListPlugins ¶ added in v2.6.0
ListPlugins lists the contents of a GitHub repo
func (*Service) ListRefs ¶
func (s *Service) ListRefs(ctx context.Context, q *apiclient.ListRefsRequest) (*apiclient.Refs, error)
ListRefs List a subset of the refs (currently, branches and tags) of a git repo
func (*Service) ResolveRevision ¶ added in v2.3.0
func (s *Service) ResolveRevision(ctx context.Context, q *apiclient.ResolveRevisionRequest) (*apiclient.ResolveRevisionResponse, error)
ResolveRevision resolves the revision/ambiguousRevision specified in the ResolveRevisionRequest request into a concrete revision.
func (*Service) TestRepository ¶ added in v2.1.0
func (s *Service) TestRepository(ctx context.Context, q *apiclient.TestRepositoryRequest) (*apiclient.TestRepositoryResponse, error)