controllers

package
v0.0.0-...-82d1e32 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: MIT Imports: 37 Imported by: 0

Documentation

Index

Constants

View Source
const (
	IPPolicyRuleActionAllow = "allow"
	IPPolicyRuleActionDeny  = "deny"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DomainReconciler

type DomainReconciler struct {
	client.Client

	Log           logr.Logger
	Scheme        *runtime.Scheme
	Recorder      record.EventRecorder
	DomainsClient *reserved_domains.Client
	// contains filtered or unexported fields
}

DomainReconciler reconciles a Domain object

func (*DomainReconciler) Reconcile

func (r *DomainReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.13.1/pkg/reconcile

func (*DomainReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type HTTPSEdgeReconciler

type HTTPSEdgeReconciler struct {
	client.Client

	Log      logr.Logger
	Scheme   *runtime.Scheme
	Recorder record.EventRecorder

	NgrokClientset ngrokapi.Clientset
	// contains filtered or unexported fields
}

HTTPSEdgeReconciler reconciles a HTTPSEdge object

func (*HTTPSEdgeReconciler) Reconcile

func (r *HTTPSEdgeReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.13.1/pkg/reconcile

func (*HTTPSEdgeReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type IPPolicyDiff

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

IPPolicyDiff represents the diff between the remote and spec rules for an IPPolicy. From the ngrok docs:

"IP Restrictions allow you to attach one or more IP policies to the route.
 If multiple IP policies are attached, a connection will be allowed only if
 its source IP matches at least one policy with an 'allow' action and
 does not match any policy with a 'deny' action."

This provides an iterator of the rules that need to be created,updated, and deleted in order to update the remote securely.

func (*IPPolicyDiff) NeedsCreate

func (d *IPPolicyDiff) NeedsCreate() []*ngrok.IPPolicyRuleCreate

func (*IPPolicyDiff) NeedsDelete

func (d *IPPolicyDiff) NeedsDelete() []*ngrok.IPPolicyRule

func (*IPPolicyDiff) NeedsUpdate

func (d *IPPolicyDiff) NeedsUpdate() []*ngrok.IPPolicyRuleUpdate

func (*IPPolicyDiff) Next

func (d *IPPolicyDiff) Next() bool

type IPPolicyReconciler

type IPPolicyReconciler struct {
	client.Client

	Log      logr.Logger
	Scheme   *runtime.Scheme
	Recorder record.EventRecorder

	IPPoliciesClient    *ip_policies.Client
	IPPolicyRulesClient *ip_policy_rules.Client
	// contains filtered or unexported fields
}

IPPolicyReconciler reconciles a IPPolicy object

func (*IPPolicyReconciler) Reconcile

func (r *IPPolicyReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.14.1/pkg/reconcile

func (*IPPolicyReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type IngressReconciler

type IngressReconciler struct {
	client.Client
	Log                  logr.Logger
	Scheme               *runtime.Scheme
	Recorder             record.EventRecorder
	Namespace            string
	AnnotationsExtractor annotations.Extractor
	Driver               *store.Driver
}

This implements the Reconciler for the controller-runtime https://pkg.go.dev/sigs.k8s.io/controller-runtime#section-readme

func (*IngressReconciler) Reconcile

func (r *IngressReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

This reconcile function is called by the controller-runtime manager. It is invoked whenever there is an event that occurs for a resource being watched (in our case, ingress objects). If you tail the controller logs and delete, update, edit ingress objects, you see the events come in.

func (*IngressReconciler) SetupWithManager

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

type ModuleSetReconciler

type ModuleSetReconciler struct {
	client.Client

	Log      logr.Logger
	Scheme   *runtime.Scheme
	Recorder record.EventRecorder
	Driver   *store.Driver
}

func (*ModuleSetReconciler) Reconcile

func (r *ModuleSetReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

This reconcile function is called by the controller-runtime manager. It is invoked whenever there is an event that occurs for a resource being watched (in our case, NgrokModuleSets). If you tail the controller logs and delete, update, edit ngrokmoduleset objects, you see the events come in.

func (*ModuleSetReconciler) SetupWithManager

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

type NonLeaderElectedController

type NonLeaderElectedController struct {
	controller.Controller
}

NonLeaderElectedController is a controller wrapper that does not need to be leader elected

func (NonLeaderElectedController) NeedLeaderElection

func (c NonLeaderElectedController) NeedLeaderElection() bool

NeedLoeaderElection helps NonLeaderElectedController implement the manager.LeaderElectionRunnable interface.

type OAuthProvider

type OAuthProvider interface {
	ClientSecretKeyRef() *ingressv1alpha1.SecretKeyRef
	ToNgrok(*string) *ngrok.EndpointOAuth
}

type TCPEdgeReconciler

type TCPEdgeReconciler struct {
	client.Client

	Log      logr.Logger
	Scheme   *runtime.Scheme
	Recorder record.EventRecorder

	controllers.IpPolicyResolver

	NgrokClientset ngrokapi.Clientset
	// contains filtered or unexported fields
}

TCPEdgeReconciler reconciles a TCPEdge object

func (*TCPEdgeReconciler) Reconcile

func (r *TCPEdgeReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.13.1/pkg/reconcile

func (*TCPEdgeReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type TLSEdgeReconciler

type TLSEdgeReconciler struct {
	client.Client

	Log      logr.Logger
	Scheme   *runtime.Scheme
	Recorder record.EventRecorder

	controllers.IpPolicyResolver

	NgrokClientset ngrokapi.Clientset
	// contains filtered or unexported fields
}

TLSEdgeReconciler reconciles a TLSEdge object

func (*TLSEdgeReconciler) Reconcile

func (r *TLSEdgeReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.13.1/pkg/reconcile

func (*TLSEdgeReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager.

type TunnelReconciler

type TunnelReconciler struct {
	client.Client

	Log          logr.Logger
	Scheme       *runtime.Scheme
	Recorder     record.EventRecorder
	TunnelDriver *tunneldriver.TunnelDriver
	// contains filtered or unexported fields
}

TunnelReconciler reconciles a Tunnel object

func (*TunnelReconciler) Reconcile

func (r *TunnelReconciler) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

Reconcile is part of the main kubernetes reconciliation loop which aims to move the current state of the cluster closer to the desired state.

For more details, check Reconcile and its Result here: - https://pkg.go.dev/sigs.k8s.io/controller-runtime@v0.13.1/pkg/reconcile

func (*TunnelReconciler) SetupWithManager

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

SetupWithManager sets up the controller with the Manager

Jump to

Keyboard shortcuts

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