Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GitSyncSource ¶
type GitSyncSource struct {
// Repository is a reference to the repository to fetch & sync from.
Repository gitproviders.Repository
// Branch is the Git branch to fetch & sync.
Branch string
// Revision is the GitRef (branch, tag, ref, or commit) to fetch & sync.
Revision string
// SourceFormat of the repository
SourceFormat configsync.SourceFormat
// Directory is the path within the repository to sync to the cluster.
Directory string
// ExpectedDirectory is the path within the source to sync to the cluster.
// Used to validate the RSync status.
ExpectedDirectory string
// ExpectedCommit is the Git commit expected to be pulled by the reconciler.
// Used to validate the RSync status.
ExpectedCommit string
}
GitSyncSource is the "git" source, backed by a Git repository.
func (*GitSyncSource) Commit ¶
func (s *GitSyncSource) Commit() (string, error)
Commit returns the current commit hash targeted by the local git repository.
func (*GitSyncSource) Path ¶
func (s *GitSyncSource) Path() string
Path within the git repository to sync to the cluster.
func (*GitSyncSource) String ¶
func (s *GitSyncSource) String() string
func (*GitSyncSource) Type ¶
func (s *GitSyncSource) Type() configsync.SourceType
Type returns the SourceType of this source.
type HelmSyncSource ¶
type HelmSyncSource struct {
// ChartID is the ID of the Helm chart.
// Used to set the RSync spec.
ChartID registryproviders.HelmChartID
// ExpectedChartVersion is the version of the Helm chart.
// Used to validate the RSync status.
ExpectedChartVersion string
}
HelmSyncSource is the "helm" source, backed by a Helm chart.
func (*HelmSyncSource) Commit ¶
func (s *HelmSyncSource) Commit() (string, error)
Commit returns the version of the current chart.
func (*HelmSyncSource) Path ¶
func (s *HelmSyncSource) Path() string
Path returns the name of the current chart.
func (*HelmSyncSource) String ¶
func (s *HelmSyncSource) String() string
func (*HelmSyncSource) Type ¶
func (s *HelmSyncSource) Type() configsync.SourceType
Type returns the SourceType of this source.
type OCISyncSource ¶
type OCISyncSource struct {
// ImageID is the ID of the OCI image.
// Used to set the RSync spec.
ImageID registryproviders.OCIImageID
// Directory is the path within the OCI image to sync to the cluster.
// Used to set the RSync spec.
Directory string
// ExpectedDirectory is the path within the OCI image to sync to the cluster.
// Used to validate the RSync status.
ExpectedDirectory string
// ImageDigest of the OCI image, including "sha256:" prefix.
// Used to validate the RSync status.
ExpectedImageDigest string
}
OCISyncSource is the "oci" source, backed by an OCI image.
func (*OCISyncSource) Commit ¶
func (s *OCISyncSource) Commit() (string, error)
Commit is not yet implemented.
func (*OCISyncSource) Path ¶
func (s *OCISyncSource) Path() string
Path within the OCI image to sync to the cluster.
func (*OCISyncSource) String ¶
func (s *OCISyncSource) String() string
func (*OCISyncSource) Type ¶
func (s *OCISyncSource) Type() configsync.SourceType
Type returns the SourceType of this source.
type Set ¶
type Set map[core.ID]SyncSource
Set of RootSync & RepoSync IDs that map to SyncSources.
func (Set) GitSyncSources ¶
GitSyncSources returns a Set that only contains RootSyncs & RepoSyncs using GitSyncSources.
func (Set) HelmSyncSources ¶
HelmSyncSources returns a Set that only contains RootSyncs & RepoSyncs using HelmSyncSources.
func (Set) OCISyncSources ¶
OCISyncSources returns a Set that only contains RootSyncs & RepoSyncs using OCISyncSources.
type SyncSource ¶
type SyncSource interface {
// Type returns the SourceType of this source.
Type() configsync.SourceType
// Commit returns the current/latest "commit" for this source.
// The value is used to validate RSync status and metrics.
Commit() (string, error)
// Path within the source to sync to the cluster.
// For Helm charts, the value represents the chart name instead.
// The value is used to validate RSync status.
Path() string
}
SyncSource describes the common methods available on all sources of truth.