gcp

package
v0.1.79 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2026 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitGCPComputeService

func InitGCPComputeService(ctx context.Context) (*compute.Service, error)

InitGCPComputeService initializes the GCP Compute Service client

Types

type ComputeClient added in v0.1.79

type ComputeClient interface {
	ListForwardingRules(ctx context.Context, project, region, filter string) ([]*compute.ForwardingRule, error)
	ListSubnetworks(ctx context.Context, project, region, filter string) ([]*compute.Subnetwork, error)
	ListServiceAttachments(ctx context.Context, project, region string) ([]*compute.ServiceAttachment, error)
	GetServiceAttachment(ctx context.Context, project, region, name string) (*compute.ServiceAttachment, error)
	InsertServiceAttachment(ctx context.Context, project, region string, sa *compute.ServiceAttachment) (*compute.Operation, error)
	DeleteServiceAttachment(ctx context.Context, project, region, name string) (*compute.Operation, error)
}

ComputeClient abstracts the GCP Compute API calls used by the PSC controller. Using an interface instead of *compute.Service enables unit testing with fakes.

type GCPPrivateServiceConnectReconciler

type GCPPrivateServiceConnectReconciler struct {
	client.Client
	upsert.CreateOrUpdateProvider
	GcpClient ComputeClient
	ProjectID string
	Region    string
	Log       logr.Logger
}

GCPPrivateServiceConnectReconciler reconciles GCPPrivateServiceConnect resources

func (*GCPPrivateServiceConnectReconciler) Reconcile

Reconcile reconciles GCPPrivateServiceConnect resources

func (*GCPPrivateServiceConnectReconciler) SetupWithManager

func (r *GCPPrivateServiceConnectReconciler) 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