dhcp

package
v0.1.0-beta.0 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2025 License: MPL-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package dhcp implements DHCP proxy and other DHCP related functionality.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Firmware

type Firmware int

Firmware describes a kind of firmware attempting to boot.

This should only be used for selecting the right bootloader, kernel selection should key off the more generic architecture.

const (
	FirmwareUnsupported Firmware = iota // Unsupported
	FirmwareX86PC                       // "Classic" x86 BIOS with PXE/UNDI support
	FirmwareX86EFI                      // EFI x86
	FirmwareARMEFI                      // EFI ARM64
	FirmwareX86Ipxe                     // "Classic" x86 BIOS running iPXE (no UNDI support)
	FirmwareX86HTTP                     // HTTP Boot X86
	FirmwareARMHTTP                     // ARM64 HTTP Boot
)

The bootloaders that we know how to handle.

type Proxy

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

Proxy is a DHCP proxy server, adding PXE boot options to the DHCP responses.

func NewProxy

func NewProxy(apiAdvertiseAddress string, apiPort int, proxyIfaceOrIP string, logger *zap.Logger) *Proxy

NewProxy creates a new DHCP proxy server.

func (*Proxy) Run

func (p *Proxy) Run(ctx context.Context) error

Run starts the DHCP proxy server.

Jump to

Keyboard shortcuts

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