kubernetesapply

package
v0.23.2 Latest Latest
Warning

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

Go to latest
Published: Dec 3, 2021 License: Apache-2.0 Imports: 37 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComputeInputHash

func ComputeInputHash(spec v1alpha1.KubernetesApplySpec, imageMaps map[types.NamespacedName]*v1alpha1.ImageMap) (string, error)

Compute the hash of all the inputs we fed into this apply.

Types

type ForceApplyStatus added in v0.23.1

type ForceApplyStatus struct {
	ResultYAML         string
	Error              string
	LastApplyTime      metav1.MicroTime
	LastApplyStartTime metav1.MicroTime
	AppliedInputHash   string
}

Partial KubernetesApplyStatus that represents the fields returned by `ForceApply`

type Reconciler

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

func NewReconciler

func NewReconciler(ctrlClient ctrlclient.Client, k8sClient k8s.Client, scheme *runtime.Scheme, dkc build.DockerKubeConnection, kubeContext k8s.KubeContext, st store.RStore, cfgNS k8s.Namespace, execer localexec.Execer) *Reconciler

func (*Reconciler) CreateBuilder

func (r *Reconciler) CreateBuilder(mgr ctrl.Manager) (*builder.Builder, error)

func (*Reconciler) ForceApply

Inject the images into the YAML and apply it to the cluster, unconditionally.

Update the apiserver when finished.

We expose this as a public method as a hack! Currently, in Tilt, BuildController handles dependencies between resources. The API server doesn't know about build dependencies yet. So Tiltfile-owned resources are applied manually, rather than going through the normal reconcile system.

func (*Reconciler) Reconcile

func (r *Reconciler) Reconcile(ctx context.Context, request reconcile.Request) (reconcile.Result, error)

Reconcile manages namespace watches for the modified KubernetesApply object.

type Result added in v0.21.0

type Result struct {
	Spec             v1alpha1.KubernetesApplySpec
	ImageMapSpecs    []v1alpha1.ImageMapSpec
	ImageMapStatuses []v1alpha1.ImageMapStatus

	AppliedObjects objectRefSet
	Status         v1alpha1.KubernetesApplyStatus
}

Keeps track of the state we currently know about.

Jump to

Keyboard shortcuts

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