config

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: May 5, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AnnotationCloudflareTunnelName = "cloudflare.com/tunnel-name"
	// AnnotationCloudflareTunnelId           = "cloudflare.com/tunnel-id"
	AnnotationCloudflareTunnelExternalName = "cloudflare.com/tunnel-external-name"
	AnnotationCloudflareTunnelPort         = "cloudflare.com/tunnel-port"
	// CloudflareTunnelAccountId    = "cloudflare.com/tunnel-account-id"
	// CloudflareTunnelZoneId       = "cloudflare.com/tunnel-zone-id"
	AnnotationCloudflareTunnelKeySecret = "cloudflare.com/tunnel-key-secret"
)
View Source
const (
	LabelCloudflaredControllerVersion  = "cloudflared-controller/version"
	LabelCloudflaredControllerTunnelId = "cloudflared-controller/tunnel-id"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CFConfigIngress

type CFConfigIngress struct {
	Hostname      string                 `yaml:"hostname,omitempty"`
	Path          string                 `yaml:"path,omitempty"`
	Service       string                 `yaml:"service,omitempty"`
	OriginRequest *CFConfigOriginRequest `yaml:"originRequest,omitempty"`
}

type CFConfigOriginRequest

type CFConfigOriginRequest struct {
	HttpHostHeader string `yaml:"httpHostHeader,omitempty"`
}

type CFConfigYaml

type CFConfigYaml struct {
	Tunnel          string            `yaml:"tunnel"`
	CredentialsFile string            `yaml:"credentials-file"`
	Ingress         []CFConfigIngress `yaml:"ingress"`
}

type CFControllerConfig

type CFControllerConfig struct {
	KubeConfigFile     string
	PresetNamespaces   []string
	Identity           string
	NoCloudFlared      bool
	Version            string
	Debug              bool
	ShowVersion        bool
	RunningInstanceDir string
	CloudFlaredFname   string
	RestartDelay       time.Duration
	CloudFlare         struct {
		ApiUrl    string
		ApiToken  string
		AccountId string
		ZoneId    string
	}
	Leader struct {
		Name          string
		Namespace     string
		LeaseDuration time.Duration
		RenewDeadline time.Duration
		RetryPeriod   time.Duration
	}
}

func GetConfig

func GetConfig(log *zerolog.Logger, version string) (*CFControllerConfig, error)

Jump to

Keyboard shortcuts

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