controllers

package
v0.0.0-...-353ba8c Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2020 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReconcileStatus

func ReconcileStatus(
	ctx context.Context, ghCli *gh.Client, gd *deployv1alpha1.GithubDeployment,
) (bool, error)

ReconcileStatus handles telling Github about the status.

Types

type ClientForOwnerRepo

type ClientForOwnerRepo func(ctx context.Context, owner, repo string) (*gh.Client, error)

ClientForOwnerRepo gives us a gh client for a specific installation.

func ClientForOwnerRepoFromSetup

func ClientForOwnerRepoFromSetup(ghCliSetup githubwebhook.GhCliSetup) ClientForOwnerRepo

ClientForOwnerRepoFromSetup gives us a ClientForOwnerRepo functions.

type Flux

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

Flux holds all k8s resources needed for flux.

func FluxResources

func FluxResources(
	ctx context.Context, r client.Reader, meta metav1.ObjectMeta, spec deployv1alpha1.RefReleaseSpec,
) (Flux, error)

FluxResources creates the k8s resources needed to launch flux.

func (*Flux) Deploy

func (f *Flux) Deploy(ctx context.Context, log logr.Logger, c client.Client, r client.Reader) error

Deploy deploys this Flux instance to the cluster.

func (*Flux) GiveOwnership

func (f *Flux) GiveOwnership(owner metav1.Object, scheme *runtime.Scheme) error

GiveOwnership sets controller references for Flux resources.

type GithubDeploymentReconciler

type GithubDeploymentReconciler struct {
	client.Client
	Log    logr.Logger
	Scheme *runtime.Scheme
	GhCli  ClientForOwnerRepo
}

GithubDeploymentReconciler reconciles a GithubDeployment object.

func (*GithubDeploymentReconciler) Reconcile

func (r *GithubDeploymentReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

Reconcile handles GithubDeployments.

func (*GithubDeploymentReconciler) SetupWithManager

func (r *GithubDeploymentReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager initializes our controller.

type GithubDeploymentReconciliation

type GithubDeploymentReconciliation struct {
	client.Client
	Log    logr.Logger
	Scheme *runtime.Scheme
	GhCli  *gh.Client
}

GithubDeploymentReconciliation is the environment for a specific reconciliation.

type IngressReconciler

type IngressReconciler struct {
	client.Client
	Log    logr.Logger
	Scheme *runtime.Scheme
}

IngressReconciler reconciles an Ingress object GitKey should be base64 encoded.

func (*IngressReconciler) Reconcile

func (ir *IngressReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

Reconcile handles Ingresses.

func (*IngressReconciler) SetupWithManager

func (ir *IngressReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager initializes our controller.

type RefReleaseReconciler

type RefReleaseReconciler struct {
	client.Client
	Log       logr.Logger
	Scheme    *runtime.Scheme
	APIReader client.Reader
}

RefReleaseReconciler reconciles a RefRelease object GitKey should be base64 encoded

func (*RefReleaseReconciler) Reconcile

func (r *RefReleaseReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

Reconcile handles RefRelease

func (*RefReleaseReconciler) SetupWithManager

func (r *RefReleaseReconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager initializes our controller

Jump to

Keyboard shortcuts

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