Documentation ¶
Index ¶
- Constants
- func ConfTmpl(tmplText string, cfg *ctrld.Config) (string, error)
- func ConfTmplWithCacheDisabled(tmplText string, cfg *ctrld.Config, cacheDisabled bool) (string, error)
- func FirewallaConfTmpl(tmplText string, cfg *ctrld.Config) (string, error)
- func FirewallaSelfInterfaces() []*net.Interface
- func InterfaceNameFromConfig(filename string) (string, error)
- type Upstream
Constants ¶
View Source
const ConfigContentTmpl = `` /* 209-byte string literal not displayed */
View Source
const CtrldMarker = `# GENERATED BY ctrld - DO NOT MODIFY`
View Source
const MerlinPostConfMarker = `# GENERATED BY ctrld - EOF`
View Source
const MerlinPostConfPath = "/jffs/scripts/dnsmasq.postconf"
View Source
const MerlinPostConfTmpl = `` /* 1228-byte string literal not displayed */
Variables ¶
This section is empty.
Functions ¶
func ConfTmplWithCacheDisabled ¶ added in v1.3.4
func ConfTmplWithCacheDisabled(tmplText string, cfg *ctrld.Config, cacheDisabled bool) (string, error)
ConfTmplWithCacheDisabled is like ConfTmpl, but the caller can control whether dnsmasq cache is disabled using cacheDisabled parameter.
Generally, the caller should use ConfTmpl, but on some routers which dnsmasq config may be changed after ctrld started (like EdgeOS/Ubios, Firewalla ...), dnsmasq cache should not be disabled because the cache-size=0 generated by ctrld will conflict with router's generated config.
func FirewallaConfTmpl ¶
FirewallaConfTmpl generates dnsmasq config for Firewalla routers.
func FirewallaSelfInterfaces ¶
FirewallaSelfInterfaces returns list of interfaces that will be configured with default dnsmasq setup on Firewalla.
func InterfaceNameFromConfig ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.