Documentation ¶
Overview ¶
Package dhcp providers UDP listening and serving functionality.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Handler ¶
Handler is a type that defines the handler function to be called every time a valid DHCPv4 message is received type Handler func(ctx context.Context, conn net.PacketConn, d data.Packet).
type Server ¶
type Server struct { Conn net.PacketConn Handlers []Handler Logger logr.Logger }
Server represents a DHCPv4 server object.
Directories ¶
Path | Synopsis |
---|---|
backend
|
|
file
Package file watches a file for changes and updates the in memory DHCP data.
|
Package file watches a file for changes and updates the in memory DHCP data. |
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. |
noop
Package noop is a backend handler that does nothing.
|
Package noop is a backend handler that does nothing. |
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. |
example
|
|
fileBackend
package main is an example of how to use the dhcp package with the file backend.
|
package main is an example of how to use the dhcp package with the file backend. |
kubeBackend
package main is an example of how to use the dhcp package with the kube backend.
|
package main is an example of how to use the dhcp package with the kube backend. |
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. |
noop
Package noop is a handler that does nothing.
|
Package noop is a handler that does nothing. |
reservation
Package reservation is the handler for responding to DHCPv4 messages with only host reservations.
|
Package reservation is the handler for responding to DHCPv4 messages with only host reservations. |
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. |
Click to show internal directories.
Click to hide internal directories.