dns

package
v0.1.52 Latest Latest
Warning

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

Go to latest
Published: Mar 17, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Check

func Check(tld string) (bool, error)

Check resolves test-lerd-probe.{tld} and checks if 127.0.0.1 is in the results. Returns (true, nil) if DNS is working correctly for the given TLD.

func Setup

func Setup() error

Setup writes DNS configuration for .test resolution and restarts the resolver. On systemd-resolved + NetworkManager systems (Ubuntu etc.) it uses an NM dispatcher script. On pure systemd-resolved systems it uses a resolved drop-in. On NetworkManager-only systems it uses NM's embedded dnsmasq.

func WriteDnsmasqConfig

func WriteDnsmasqConfig(dir string) error

WriteDnsmasqConfig writes the lerd dnsmasq config to the given directory. Upstream DNS servers are detected from the running system so they are never hardcoded.

Types

This section is empty.

Jump to

Keyboard shortcuts

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