smee

package
v0.0.0-...-08b716b Latest Latest
Warning

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

Go to latest
Published: Jan 30, 2024 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// GitRev is the git revision of the build. It is set by the Makefile.
	GitRev = "unknown (use make)"
)

Functions

This section is empty.

Types

type DhcpBackends

type DhcpBackends struct {
	Kubernetes Kube
}

type DhcpConfig

type DhcpConfig struct {
	Enabled           bool
	Mode              string
	BindAddr          string
	BindInterface     string
	IpForPacket       string
	SyslogIP          string
	TftpIP            string
	HttpIpxeBinaryURL string
	HttpIpxeScript    HttpIpxeScript
}

type File

type File struct {
	// FilePath is the path to a JSON FilePath containing hardware data.
	FilePath string
	Enabled  bool
}

type HttpIpxeScript

type HttpIpxeScript struct {
	Url string
	// injectMacAddress will prepend the hardware mac address to the ipxe script URL file name.
	// For example: http://1.2.3.4/my/loc/auto.ipxe -> http://1.2.3.4/my/loc/40:15:ff:89:cc:0e/auto.ipxe
	// Setting this to false is useful when you are not using the auto.ipxe script in Smee.
	InjectMacAddress bool
}

type IpxeHTTPBinary

type IpxeHTTPBinary struct {
	Enabled bool
}

type IpxeHTTPScript

type IpxeHTTPScript struct {
	Enabled                       bool
	BindAddr                      string
	ExtraKernelArgs               string
	HookURL                       string
	TinkServer                    string
	TinkServerUseTLS              bool
	TrustedProxies                string
	DisableDiscoverTrustedProxies bool
}

type Kube

type Kube struct {
	// ConfigFilePath is the path to a kubernetes config file (kubeconfig).
	ConfigFilePath string
	// APIURL is the Kubernetes API URL.
	APIURL string
	// Namespace is an override for the Namespace the kubernetes client will watch.
	// The default is the Namespace the pod is running in.
	Namespace string
	Enabled   bool
}

type Service

type Service struct {
	Syslog         SyslogConfig
	Tftp           Tftp
	IpxeHTTPBinary IpxeHTTPBinary
	IpxeHTTPScript IpxeHTTPScript
	Dhcp           DhcpConfig

	// loglevel is the log level for smee.
	LogLevel string
	Backends DhcpBackends
	Logger   logr.Logger
}

func (Service) Start

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

type SyslogConfig

type SyslogConfig struct {
	Enabled  bool
	BindAddr string
}

type Tftp

type Tftp struct {
	BindAddr        string
	BlockSize       int
	Enabled         bool
	IpxeScriptPatch string
	Timeout         time.Duration
}

Directories

Path Synopsis
backend
kube
Package kube is a backend implementation that uses the Tinkerbell CRDs to get DHCP data.
Package kube is a backend implementation that uses the Tinkerbell CRDs to get DHCP data.
data
Package data is an interface between DHCP backend implementations and the DHCP server.
Package data is an interface between DHCP backend implementations and the DHCP server.
handler
Package handler holds the interface that backends implement, handlers take in, and the top level dhcp package passes to handlers.
Package handler holds the interface that backends implement, handlers take in, and the top level dhcp package passes to handlers.
handler/proxy
Package proxy implements a DHCP handler that provides proxyDHCP functionality.
Package proxy implements a DHCP handler that provides proxyDHCP functionality.
handler/reservation
Package noop is a backend handler that does nothing.
Package noop is a backend handler that does nothing.
otel
Package otel handles translating DHCP headers and options to otel key/value attributes.
Package otel handles translating DHCP headers and options to otel key/value attributes.
server
Package dhcp providers UDP listening and serving functionality.
Package dhcp providers UDP listening and serving functionality.
ipxe
http
package bhttp is the http server for smee.
package bhttp is the http server for smee.

Jump to

Keyboard shortcuts

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