internal/

directory
v0.0.0-...-b13fc33 Latest Latest
Warning

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

Go to latest
Published: Aug 7, 2026 License: Apache-2.0

README

Internal Package

Low-level code that directly interacts with system components (Kubernetes, SSH, infrastructure).

✅ What Belongs Here

Direct, atomic operations on components:

// ✅ CORRECT: Single, direct operations
GetModule(ctx, config, name)
UpdateModule(ctx, config, module)
GetModuleConfig(ctx, config, name)

❌ What Does NOT Belong Here

Business logic that orchestrates multiple operations:

// ❌ INCORRECT: Combines multiple operations with logic
EnsureModuleEnabled(ctx, config, name)    // Checks + enables
CheckSnapshotControllerReady(ctx, config)  // Polls until ready
UpdateVirtualization(ctx, config, settings) // Validates + updates

Place these in higher-level packages pkg/deckhouse/, pkg/kubernetes, pkg/testkit etc.

Rule of Thumb

One function = one direct operation. If it does multiple things or contains business logic, it doesn't belong here.

Directories

Path Synopsis
infrastructure
ssh
ssh/v2
Package ssh provides a self-healing SSH client whose connection strategy ("how we connect" — directly or through jump hosts) is separated from the operations performed over it ("what we do").
Package ssh provides a self-healing SSH client whose connection strategy ("how we connect" — directly or through jump hosts) is separated from the operations performed over it ("what we do").
kubernetes
clusterlock
Package clusterlock implements the coordination.k8s.io/v1 Lease-based cluster lock used by the pkg/e2e SDK.
Package clusterlock implements the coordination.k8s.io/v1 Lease-based cluster lock used by the pkg/e2e SDK.
kubeaccess
Package kubeaccess bundles the kubeconfig/rest.Config plumbing shared by the cluster providers (dvp, commander): fetching a kubeconfig off a master over SSH, rewriting its server address, building rest.Configs with tunnel-friendly transport timeouts, opening an API tunnel, and probing direct reachability.
Package kubeaccess bundles the kubeconfig/rest.Config plumbing shared by the cluster providers (dvp, commander): fetching a kubeconfig off a master over SSH, rewriting its server address, building rest.Configs with tunnel-friendly transport timeouts, opening an API tunnel, and probing direct reachability.
provisioning
commander
Package commander implements a clusterprovider.Provider that creates and removes test clusters through the Deckhouse Commander API.
Package commander implements a clusterprovider.Provider that creates and removes test clusters through the Deckhouse Commander API.
dvp

Jump to

Keyboard shortcuts

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