version

package
v1.78.0 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2026 License: Apache-2.0 Imports: 3 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Getter

type Getter func() (*semver.Version, error)

Getter returns the current version (of Kubernetes, of Deckhouse).

type Rule

type Rule struct {
	// contains filtered or unexported fields
}

Rule is a version gate: Undefined or Forbid.

func NewRule

func NewRule(getter Getter, constraints *semver.Constraints, subject, reason string) *Rule

NewRule creates a version rule. subject repeats reason in a form fit for the message, which is all the user gets on the admission path.

func (*Rule) Decide

func (r *Rule) Decide() rule.Decision

Decide forbids when the version cannot be read or does not satisfy the constraints.

Jump to

Keyboard shortcuts

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