Documentation
¶
Index ¶
Constants ¶
const DefaultAPIServerPort = 6443
const DefaultAPIServerReadyTimeout = 5 * time.Minute
DefaultAPIServerReadyTimeout is the time limit for the kube-apiserver of a control-plane node after a reboot.
const DefaultControlPlaneCPUDedicated = 4
const DefaultControlPlaneCPUSchedulable = 4
const DefaultControlPlaneMemoryDedicated = 8
const DefaultControlPlaneMemorySchedulable = 12
const DefaultConvergeTimeout = 5 * time.Minute
DefaultConvergeTimeout is the time limit to reconcile stalled kustomizations and HelmReleases during an install.
const DefaultFluxKustomizationForce = false
const DefaultFluxKustomizationInstallTimeout = 10 * time.Minute
DefaultFluxKustomizationInstallTimeout is the timeout of an install tier when the facet sets none.
const DefaultFluxKustomizationInterval = 1 * time.Hour
DefaultFluxKustomizationInterval is the backstop reconciliation interval for a Kustomization of a vendor source.
const DefaultFluxKustomizationRetryInterval = 2 * time.Minute
const DefaultFluxKustomizationTimeout = 5 * time.Minute
const DefaultFluxKustomizationWait = true
const DefaultFluxPrimaryKustomizationInterval = 5 * time.Minute
DefaultFluxPrimaryKustomizationInterval is the backstop reconciliation interval for a Kustomization of the blueprint repository.
const DefaultFluxPrimaryRepositoryInterval = 1 * time.Minute
DefaultFluxPrimaryRepositoryInterval is the poll interval for the repository of the blueprint.
const DefaultFluxSourceInterval = 1 * time.Hour
DefaultFluxSourceInterval is the backstop reconciliation interval for a vendor source.
const DefaultFluxSourceTimeout = 2 * time.Minute
const DefaultGitopsNamespace = "system-gitops"
const DefaultKubernetesReachabilityCheckTimeout = 30 * time.Second
DefaultKubernetesReachabilityCheckTimeout is the time limit of the Kubernetes check before a destroy.
const DefaultKustomizationWaitMaxFailures = 5
DefaultKustomizationWaitMaxFailures is the number of consecutive failures before the CLI wait stops.
const DefaultKustomizationWaitPollInterval = 5 * time.Second
DefaultKustomizationWaitPollInterval is the poll interval of the CLI kustomization wait.
const DefaultKustomizationWaitTotalTimeout = 10 * time.Minute
DefaultKustomizationWaitTotalTimeout is the time limit of one CLI wait for all kustomizations.
const DefaultLoadBalancerTeardownTimeout = 15 * time.Minute
DefaultLoadBalancerTeardownTimeout is the time limit for a cloud controller to remove a LoadBalancer Service finalizer.
const DefaultNetworkCIDR = "10.5.0.0/16"
const DefaultNodeHealthCheckPollInterval = 10 * time.Second
const DefaultNodeHealthCheckTimeout = 5 * time.Minute
const DefaultNodeOfflineTimeout = 3 * time.Minute
const DefaultNodeUpgradeTimeout = 10 * time.Minute
const DefaultOCIBlueprintURL = "oci://ghcr.io/windsorcli/core:latest"
const DefaultTerraformDestroyAbsoluteTimeout = 2 * time.Hour
DefaultTerraformDestroyAbsoluteTimeout is the total time limit of one `terraform destroy`.
const DefaultTerraformDestroyGracePeriod = 2 * time.Minute
DefaultTerraformDestroyGracePeriod is the wait between the interrupt and the kill of a timed-out destroy.
const DefaultTerraformDestroyIdleTimeout = 5 * time.Minute
DefaultTerraformDestroyIdleTimeout is the time limit without output from `terraform destroy`.
const DefaultTerraformDestroyRetryAttempts = 2
DefaultTerraformDestroyRetryAttempts is the number of destroy attempts for one component. Only a failure before the timeout gets a retry.
const DefaultTerraformDestroyRetryBackoff = 30 * time.Second
DefaultTerraformDestroyRetryBackoff is the wait between two destroy attempts.
const DefaultTerraformRefreshTimeout = 2 * time.Minute
DefaultTerraformRefreshTimeout is the time limit of the terraform refresh before a destroy.
const DefaultWorkerCPU = 4
const DefaultWorkerMemory = 8
const KubernetesShortTimeout = 200 * time.Millisecond
const MinimumVersion1Password = "2.15.0"
const MinimumVersionAWS = "2.0.0"
const MinimumVersionAzure = "2.50.0"
const MinimumVersionColima = "0.9.0"
const MinimumVersionDocker = "23.0.0"
const MinimumVersionGCP = "400.0.0"
const MinimumVersionKubelogin = "0.1.7"
const MinimumVersionLima = "1.0.0"
const MinimumVersionLimaIncus = "2.0.3"
MinimumVersionLimaIncus is the minimum limactl version for colima with the incus platform.
const MinimumVersionSOPS = "3.10.0"
const MinimumVersionTerraform = "1.12.2"
Variables ¶
var BuildDate = "unknown"
BuildDate is the build time in RFC 3339 format. goreleaser sets it with ldflags. It keeps its default value after `go build` or `go install`.
var CommitSHA = "none"
CommitSHA is the git commit SHA. The build sets it with ldflags.
var PinnedBlueprintURL = ""
PinnedBlueprintURL is the blueprint URL of a release build. goreleaser sets it with ldflags.
var Version = "dev"
Version is the CLI version. The build sets it with ldflags.
Functions ¶
func FluxKustomizationInterval ¶ added in v0.9.0
FluxKustomizationInterval returns the default reconciliation interval for a Kustomization. isPrimarySource is true when the Kustomization uses the repository of the blueprint, not a vendor source. A short interval causes DependencyNotReady retries, so this interval is longer than the source interval.
func FluxSourceInterval ¶ added in v0.9.0
FluxSourceInterval returns the default reconciliation interval for a GitRepository or OCIRepository. isPrimary is true for the repository in the top-level "repository:" field of the blueprint. A push to the blueprint repository can occur without a windsor command, so its poll interval is short.
func GetEffectiveBlueprintURL ¶ added in v0.7.0
func GetEffectiveBlueprintURL() string
GetEffectiveBlueprintURL returns PinnedBlueprintURL when the build sets it, or DefaultOCIBlueprintURL.
Types ¶
type GitopsMode ¶ added in v0.9.0
type GitopsMode string
GitopsMode is the gitops mode of a context. Pull and push use the same reconciliation intervals.
const ( GitopsModePull GitopsMode = "pull" GitopsModePush GitopsMode = "push" )
func ParseGitopsMode ¶ added in v0.9.0
func ParseGitopsMode(s string) GitopsMode
ParseGitopsMode returns the GitopsMode for a config value. It returns "pull" for an empty or unknown value, so a typo gives the safe mode and not an error.