INNER CODE UNIT · Go

main

deckhouse/deckhouse · deckhouse-controller/cmd/deckhouse-controller/main.go:63

func main() {
	app.SetShellOperatorVersion(ShellOperatorVersion)
	app.SetAddonOperatorVersion(AddonOperatorVersion)
	app.SetDeckhouseVersion(DeckhouseVersion)

	// deckhouse-controller is the single source of truth for environment-driven
	// configuration of addon-operator (and the shell-operator globals
	// addon-operator manages). We start from addon-operator's hardcoded
	// defaults, then layer the env vars promised by the deckhouse-controller
	// deployment manifest on top via envconfig.Load. addon-operator's own
	// ParseEnv is intentionally not called: upstream renames (e.g. addon-operator
	// v1.21 moved MODULES_DIR under ADDON_OPERATOR_MODULES_DIR) must not
	// silently change the deckhouse env contract.
	cfg := app.NewConfig()
	if err := envconfig.Load(cfg); err != nil {
		fmt.Fprintf(os.Stderr, "configuration error: %v\n", err)
		os.Exit(1)
	}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…