addonclients

package
v0.10.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FluxChangeDiff added in v0.7.0

func FluxChangeDiff(currentSpec, newSpec *cluster.Spec) *types.ChangeDiff

Types

type ConfigVersionControlFailedError

type ConfigVersionControlFailedError struct {
	Err error
}

func (*ConfigVersionControlFailedError) Error

type Flux

type Flux interface {
	// BootstrapToolkitsComponentsGithub bootstraps toolkit components in a GitHub repository.
	BootstrapToolkitsComponentsGithub(ctx context.Context, cluster *types.Cluster, fluxConfig *v1alpha1.FluxConfig) error

	// BootstrapToolkitsComponentsGit bootstraps toolkit componets in a generic Git repository
	BootstrapToolkitsComponentsGit(ctx context.Context, cluster *types.Cluster, fluxConfig *v1alpha1.FluxConfig, cliConfig *config.CliConfig) error

	// UninstallToolkitsComponents UninstallFluxComponents removes the Flux components and the toolkit.fluxcd.io resources from the cluster.
	UninstallToolkitsComponents(ctx context.Context, cluster *types.Cluster, fluxConfig *v1alpha1.FluxConfig) error

	// PauseKustomization pauses reconciliation of Kustomization
	PauseKustomization(ctx context.Context, cluster *types.Cluster, fluxConfig *v1alpha1.FluxConfig) error

	// ResumeKustomization resumes a paused Kustomization
	ResumeKustomization(ctx context.Context, cluster *types.Cluster, fluxConfig *v1alpha1.FluxConfig) error

	// ForceReconcileGitRepo sync git repo with latest commit
	ForceReconcileGitRepo(ctx context.Context, cluster *types.Cluster, namespace string) error

	// DeleteFluxSystemSecret deletes flux-system secret
	DeleteFluxSystemSecret(ctx context.Context, cluster *types.Cluster, namespace string) error

	// Reconcile reconciles sources and resources
	Reconcile(ctx context.Context, cluster *types.Cluster, fluxConfig *v1alpha1.FluxConfig) error
}

Flux is an interface that abstracts the basic commands of flux executable.

type FluxAddonClient

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

func NewFluxAddonClient

func NewFluxAddonClient(flux Flux, gitTools *gitFactory.GitTools, cliConfig *config.CliConfig) *FluxAddonClient

func (*FluxAddonClient) CleanupGitRepo

func (f *FluxAddonClient) CleanupGitRepo(ctx context.Context, clusterSpec *cluster.Spec) error

func (*FluxAddonClient) ForceReconcileGitRepo

func (f *FluxAddonClient) ForceReconcileGitRepo(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec) error

func (*FluxAddonClient) InstallGitOps

func (f *FluxAddonClient) InstallGitOps(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec, datacenterConfig providers.DatacenterConfig, machineConfigs []providers.MachineConfig) error

InstallGitOps validates and sets up the gitops/flux config, creates a repository if one doesn’t exist, commits the manifests for both eks-a cluster and flux components to the default branch at the specified path, and installs the Flux components. Then it configures the target cluster to synchronize with the specified path inside the repository.

func (*FluxAddonClient) PauseGitOpsKustomization

func (f *FluxAddonClient) PauseGitOpsKustomization(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec) error

func (*FluxAddonClient) ResumeGitOpsKustomization

func (f *FluxAddonClient) ResumeGitOpsKustomization(ctx context.Context, cluster *types.Cluster, clusterSpec *cluster.Spec) error

func (*FluxAddonClient) SetRetier

func (f *FluxAddonClient) SetRetier(retrier *retrier.Retrier)

func (*FluxAddonClient) UpdateGitEksaSpec

func (f *FluxAddonClient) UpdateGitEksaSpec(ctx context.Context, clusterSpec *cluster.Spec, datacenterConfig providers.DatacenterConfig, machineConfigs []providers.MachineConfig) error

func (*FluxAddonClient) UpdateLegacyFileStructure added in v0.6.1

func (f *FluxAddonClient) UpdateLegacyFileStructure(ctx context.Context, currentSpec *cluster.Spec, newSpec *cluster.Spec) error

func (*FluxAddonClient) Upgrade added in v0.6.0

func (f *FluxAddonClient) Upgrade(ctx context.Context, managementCluster *types.Cluster, currentSpec *cluster.Spec, newSpec *cluster.Spec) (*types.ChangeDiff, error)

func (*FluxAddonClient) Validations

func (f *FluxAddonClient) Validations(ctx context.Context, clusterSpec *cluster.Spec) []validations.Validation

Directories

Path Synopsis
Package mocks is a generated GoMock package.
Package mocks is a generated GoMock package.

Jump to

Keyboard shortcuts

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