nodeconfig

package
v1.21.5 Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2026 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package nodeconfig resolves the node configuration a server's nodes run with: the global node settings and the server's override of them, whose fields each either inherit (NULL) or replace a global value.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyOverride

func ApplyOverride(values *dto.ServerNodeConfigValues, override *node.ServerConfigOverride) error

ApplyOverride replaces the values the override sets; a missing override changes nothing.

func CloneValues

CloneValues deep-copies values, normalizing its string lists and giving the DNS and outbound lists their defaults when empty.

func GlobalValues

GlobalValues is the node configuration every server inherits, normalized like any other configuration values.

func OverrideModel

func OverrideModel(serverID int64, req dto.ServerNodeConfigOverride) (*node.ServerConfigOverride, bool, error)

OverrideModel is the stored form of a server's override as the API sets it, and whether it inherits every value, in which case nothing need be stored.

func OverrideResponse

func OverrideResponse(override *node.ServerConfigOverride) (dto.ServerNodeConfigOverride, error)

OverrideResponse is the API form of a server's override: each value it does not set is marked inherited.

Types

This section is empty.

Jump to

Keyboard shortcuts

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