tunnel

package
v2.2.3 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package tunnel provides tunnel orchestration functionality.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DNSRecordConfig added in v2.1.0

type DNSRecordConfig struct {
	Zone      string         `json:"zone"`
	Tunnel    *domain.Tunnel `json:"tunnel"`
	Subdomain string         `json:"subdomain"`
}

DNSRecordConfig represents the desired DNS record configuration

type DNSRecordHandler

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

DNSRecordHandler manages DNS record lifecycle with type safety

func (*DNSRecordHandler) CheckFromConfig added in v2.1.0

func (h *DNSRecordHandler) CheckFromConfig(ctx context.Context, config DNSRecordConfig) (DNSRecordState, domain.State, error)

CheckFromConfig finds existing DNS record from config and returns state + status

func (*DNSRecordHandler) CheckFromState added in v2.1.0

func (h *DNSRecordHandler) CheckFromState(ctx context.Context, state DNSRecordState) (domain.State, error)

func (*DNSRecordHandler) Create added in v2.1.0

func (*DNSRecordHandler) Destroy added in v2.1.0

func (h *DNSRecordHandler) Destroy(ctx context.Context, state DNSRecordState) error

func (*DNSRecordHandler) Equals added in v2.1.0

func (h *DNSRecordHandler) Equals(a, b DNSRecordConfig) bool

func (*DNSRecordHandler) Name

func (h *DNSRecordHandler) Name() string

type DNSRecordState added in v2.1.0

type DNSRecordState struct {
	Zone      string         `json:"zone"`
	Tunnel    *domain.Tunnel `json:"tunnel"`
	Subdomain string         `json:"subdomain"`
}

DNSRecordState represents the runtime state of a created DNS record

type Service

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

func NewService

func NewService(tunnel *domain.Tunnel, ingress *domain.Ingress, dnsService ports.DNSService, tunnelService ports.TunnelService) *Service

func (*Service) Start

func (s *Service) Start(ctx context.Context) error

func (*Service) Stop

func (s *Service) Stop(ctx context.Context) error

type TunnelConfigConfig added in v2.1.0

type TunnelConfigConfig struct {
	Tunnel  *domain.Tunnel  `json:"tunnel"`
	Ingress *domain.Ingress `json:"ingress"`
}

TunnelConfigConfig represents the desired tunnel configuration

type TunnelConfigHandler

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

TunnelConfigHandler manages tunnel configuration lifecycle with type safety

func (*TunnelConfigHandler) CheckFromConfig added in v2.1.0

CheckFromConfig finds existing tunnel configuration from config and returns state + status

func (*TunnelConfigHandler) CheckFromState added in v2.1.0

func (h *TunnelConfigHandler) CheckFromState(ctx context.Context, state TunnelConfigState) (domain.State, error)

func (*TunnelConfigHandler) Create added in v2.1.0

func (*TunnelConfigHandler) Destroy added in v2.1.0

func (*TunnelConfigHandler) Equals added in v2.1.0

func (*TunnelConfigHandler) Name

func (h *TunnelConfigHandler) Name() string

type TunnelConfigState added in v2.1.0

type TunnelConfigState struct {
	Tunnel     *domain.Tunnel  `json:"tunnel"`
	Ingress    *domain.Ingress `json:"ingress"`
	ConfigPath string          `json:"config_path"`
}

TunnelConfigState represents the runtime state of a configured tunnel

type TunnelCreateConfig added in v2.1.0

type TunnelCreateConfig struct {
	Tunnel *domain.Tunnel `json:"tunnel"`
}

TunnelCreateConfig represents the desired tunnel configuration

type TunnelCreateHandler

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

TunnelCreateHandler manages tunnel creation lifecycle with type safety

func (*TunnelCreateHandler) CheckFromConfig added in v2.1.0

CheckFromConfig finds existing tunnel from config and returns state + status

func (*TunnelCreateHandler) CheckFromState added in v2.1.0

func (h *TunnelCreateHandler) CheckFromState(ctx context.Context, state TunnelCreateState) (domain.State, error)

func (*TunnelCreateHandler) Create added in v2.1.0

func (*TunnelCreateHandler) Destroy added in v2.1.0

func (*TunnelCreateHandler) Equals added in v2.1.0

func (*TunnelCreateHandler) Name

func (h *TunnelCreateHandler) Name() string

type TunnelCreateState added in v2.1.0

type TunnelCreateState struct {
	Tunnel *domain.Tunnel `json:"tunnel"`
}

TunnelCreateState represents the runtime state of a created tunnel

type TunnelRunConfig added in v2.1.0

type TunnelRunConfig struct {
	Tunnel *domain.Tunnel `json:"tunnel"`
}

TunnelRunConfig represents the desired tunnel run configuration

type TunnelRunHandler added in v2.1.0

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

TunnelRunHandler manages tunnel process lifecycle with type safety

func (*TunnelRunHandler) CheckFromConfig added in v2.1.0

func (h *TunnelRunHandler) CheckFromConfig(ctx context.Context, config TunnelRunConfig) (TunnelRunState, domain.State, error)

CheckFromConfig finds existing tunnel process from config and returns state + status

func (*TunnelRunHandler) CheckFromState added in v2.1.0

func (h *TunnelRunHandler) CheckFromState(ctx context.Context, state TunnelRunState) (domain.State, error)

func (*TunnelRunHandler) Create added in v2.1.0

func (*TunnelRunHandler) Destroy added in v2.1.0

func (h *TunnelRunHandler) Destroy(ctx context.Context, state TunnelRunState) error

func (*TunnelRunHandler) Equals added in v2.1.0

func (h *TunnelRunHandler) Equals(a, b TunnelRunConfig) bool

func (*TunnelRunHandler) Name added in v2.1.0

func (h *TunnelRunHandler) Name() string

type TunnelRunState added in v2.1.0

type TunnelRunState struct {
	PID    int            `json:"pid"`
	Tunnel *domain.Tunnel `json:"tunnel"`
}

TunnelRunState represents the runtime state of a running tunnel process

Jump to

Keyboard shortcuts

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