reservation.go 744 B

1234567891011121314151617181920212223
  1. // Package reservation is the handler for responding to DHCPv4 messages with only host reservations.
  2. package reservation
  3. import (
  4. "dhcp/internal/dhcpServer/handler"
  5. "github.com/go-logr/logr"
  6. "net/netip"
  7. )
  8. // Handler holds the configuration details for the running the dhcpServer server.
  9. type Handler struct {
  10. // Backend is the macAndIPXE to use for getting dhcpServer data.
  11. Backend handler.BackendReader
  12. // IPAddr is the IP address to use in dhcpServer responses.
  13. // Option 54 and the sname dhcpServer header.
  14. // This could be a load balancer IP address or an ingress IP address or a local IP address.
  15. IPAddr netip.Addr
  16. // Log is used to log messages.
  17. // `logr.Discard()` can be used if no logging is desired.
  18. Log logr.Logger
  19. }