From ab46e4f9c61b2df1ca3ab0dd383a772140bac045 Mon Sep 17 00:00:00 2001 From: Takashiidobe Date: Thu, 25 Jan 2024 20:51:07 -0500 Subject: [PATCH] fix typos using https://crates.io/crates/typos-cli --- charts/karpenter/templates/deployment.yaml | 4 ++-- designs/aks-node-bootstrap.md | 2 +- designs/gpu-selection-and-bootstrap.md | 6 +++--- designs/k8s-node-image-upgrade.md | 2 +- pkg/fake/types.go | 2 +- pkg/providers/imagefamily/resolver.go | 2 +- pkg/providers/instancetype/suite_test.go | 4 ++-- pkg/providers/pricing/pricing.go | 2 +- test/pkg/debug/events.go | 8 ++++---- 9 files changed, 16 insertions(+), 16 deletions(-) diff --git a/charts/karpenter/templates/deployment.yaml b/charts/karpenter/templates/deployment.yaml index d86cf7cc3..5f606eef0 100644 --- a/charts/karpenter/templates/deployment.yaml +++ b/charts/karpenter/templates/deployment.yaml @@ -187,13 +187,13 @@ spec: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.affinity }} - # The template below patches the .Values.affinity to add a default label selector where not specificed + # The template below patches the .Values.affinity to add a default label selector where not specified {{- $_ := include "karpenter.patchAffinity" $ }} affinity: {{- toYaml . | nindent 8 }} {{- end }} {{- with .Values.topologySpreadConstraints }} - # The template below patches the .Values.topologySpreadConstraints to add a default label selector where not specificed + # The template below patches the .Values.topologySpreadConstraints to add a default label selector where not specified {{- $_ := include "karpenter.patchTopologySpreadConstraints" $ }} topologySpreadConstraints: {{- toYaml . | nindent 8 }} diff --git a/designs/aks-node-bootstrap.md b/designs/aks-node-bootstrap.md index ae5c3c6ed..1b6efa0c8 100644 --- a/designs/aks-node-bootstrap.md +++ b/designs/aks-node-bootstrap.md @@ -103,7 +103,7 @@ Karpenter also supports provider-specific configuration via `NodeTemplate` custo Note that this represents part of the external configuration surface / API, and should be treated as such. - + ### Auto-detected values diff --git a/designs/gpu-selection-and-bootstrap.md b/designs/gpu-selection-and-bootstrap.md index 052db04cf..97e1f6540 100644 --- a/designs/gpu-selection-and-bootstrap.md +++ b/designs/gpu-selection-and-bootstrap.md @@ -74,7 +74,7 @@ The way we determine these drivers is via trial and error, and there is not a gr For Converged drivers they are a mix of multiple drivers installing vanilla cuda drivers will fail to install with opaque errors. nvidia-bug-report.sh may be helpful, but usually it tells you the pci card id is incompatible. -So manual trial and error, or leveraging other peoples manual trial and error, and published gpu drivers seems to be the prefered method for approaching this. +So manual trial and error, or leveraging other peoples manual trial and error, and published gpu drivers seems to be the preferred method for approaching this. see https://github.com/Azure/azhpc-extensions/blob/daaefd78df6f27012caf30f3b54c3bd6dc437652/NvidiaGPU/resources.json for the HPC list of skus and converged drivers, and the driver matrix used by HPC **Ownership:** Node SIG is responsible for ensuring successful and functional installation. Our goal is to share a bootstrap contract, and the oblication of a functional successfully bootstrapped vhd relies on the node sig. @@ -95,9 +95,9 @@ The NVIDIA device plugin for Kubernetes is designed to enable GPU support within We will require the customer to install the nvidia device plugin daemonset to enable GPU support through karpenter. -When a node with Nvidia GPUS joins the cluster, the device plugin detects available gpus and notifies the k8s scheduler that we have a new Allocatable Resource type of `nvidia.com/gpu` along with a resource quanity that can be considered for scheduling. +When a node with Nvidia GPUS joins the cluster, the device plugin detects available gpus and notifies the k8s scheduler that we have a new Allocatable Resource type of `nvidia.com/gpu` along with a resource quantity that can be considered for scheduling. -Note the device plugin is also reponsible for the allocation of that resource and reporting that other pods can not use that resource and marking it as used by changing the allocatable capacity on the node. +Note the device plugin is also responsible for the allocation of that resource and reporting that other pods can not use that resource and marking it as used by changing the allocatable capacity on the node. ## Changes to Requirements API diff --git a/designs/k8s-node-image-upgrade.md b/designs/k8s-node-image-upgrade.md index 5976084d2..890611654 100644 --- a/designs/k8s-node-image-upgrade.md +++ b/designs/k8s-node-image-upgrade.md @@ -310,5 +310,5 @@ From template: design doc by carefully reviewing it or assigning a tech leads that are domain expert in that SIG to review and approve this doc -[^6]: Q&A style meeting notes from desgin review meeting to capture +[^6]: Q&A style meeting notes from design review meeting to capture todos diff --git a/pkg/fake/types.go b/pkg/fake/types.go index f364dbfef..a76b22cf2 100644 --- a/pkg/fake/types.go +++ b/pkg/fake/types.go @@ -136,7 +136,7 @@ type MockHandler[T any] struct { err error } -// Done returns true if the LRO has reached a terminal state. TrivialHanlder is always done. +// Done returns true if the LRO has reached a terminal state. TrivialHandler is always done. func (h MockHandler[T]) Done() bool { return true } diff --git a/pkg/providers/imagefamily/resolver.go b/pkg/providers/imagefamily/resolver.go index 1a9e85898..c9499839a 100644 --- a/pkg/providers/imagefamily/resolver.go +++ b/pkg/providers/imagefamily/resolver.go @@ -88,7 +88,7 @@ func (r Resolver) Resolve(ctx context.Context, nodeClass *v1alpha2.AKSNodeClass, kubeletConfig = &corev1beta1.KubeletConfiguration{} } - // TODO: revist computeResources and maxPods implementation + // TODO: revisit computeResources and maxPods implementation kubeletConfig.KubeReserved = instanceType.Overhead.KubeReserved kubeletConfig.SystemReserved = instanceType.Overhead.SystemReserved kubeletConfig.EvictionHard = map[string]string{ diff --git a/pkg/providers/instancetype/suite_test.go b/pkg/providers/instancetype/suite_test.go index c542ae1d8..a002f8609 100644 --- a/pkg/providers/instancetype/suite_test.go +++ b/pkg/providers/instancetype/suite_test.go @@ -787,9 +787,9 @@ var _ = Describe("InstanceType Provider", func() { Expect(ok).To(BeTrue(), "Expected nvidia.com/gpu to be present in capacity") Expect(gpuQuantity.Value()).To(Equal(int64(1))) - gpuQuanityNonGPU, ok := normalNode.Capacity["nvidia.com/gpu"] + gpuQuantityNonGPU, ok := normalNode.Capacity["nvidia.com/gpu"] Expect(ok).To(BeTrue(), "Expected nvidia.com/gpu to be present in capacity, and be zero") - Expect(gpuQuanityNonGPU.Value()).To(Equal(int64(0))) + Expect(gpuQuantityNonGPU.Value()).To(Equal(int64(0))) }) }) diff --git a/pkg/providers/pricing/pricing.go b/pkg/providers/pricing/pricing.go index 5a1d265f7..4723794ea 100644 --- a/pkg/providers/pricing/pricing.go +++ b/pkg/providers/pricing/pricing.go @@ -162,7 +162,7 @@ func (p *Provider) updatePricing(ctx context.Context) { prices := map[client.Item]bool{} err := p.fetchPricing(ctx, processPage(prices)) if err != nil { - logging.FromContext(ctx).Errorf("error featching updated pricing for region %s, %s, using existing pricing data, on-demand: %s, spot: %s", p.region, err, err.lastOnDemandUpdateTime.Format(time.RFC3339), err.lastSpotUpdateTime.Format(time.RFC3339)) + logging.FromContext(ctx).Errorf("error fetching updated pricing for region %s, %s, using existing pricing data, on-demand: %s, spot: %s", p.region, err, err.lastOnDemandUpdateTime.Format(time.RFC3339), err.lastSpotUpdateTime.Format(time.RFC3339)) return } diff --git a/test/pkg/debug/events.go b/test/pkg/debug/events.go index 89f546c5d..80c2ef423 100644 --- a/test/pkg/debug/events.go +++ b/test/pkg/debug/events.go @@ -55,7 +55,7 @@ func (c *EventClient) dumpKarpenterEvents(ctx context.Context) error { if err := c.kubeClient.List(ctx, el, client.InNamespace("karpenter")); err != nil { return err } - for k, v := range coallateEvents(filterTestEvents(el.Items, c.start)) { + for k, v := range collateEvents(filterTestEvents(el.Items, c.start)) { fmt.Print(getEventInformation(k, v)) } return nil @@ -71,7 +71,7 @@ func (c *EventClient) dumpPodEvents(ctx context.Context) error { events := lo.Filter(filterTestEvents(el.Items, c.start), func(e v1.Event, _ int) bool { return e.InvolvedObject.Namespace != "kube-system" }) - for k, v := range coallateEvents(events) { + for k, v := range collateEvents(events) { fmt.Print(getEventInformation(k, v)) } return nil @@ -84,7 +84,7 @@ func (c *EventClient) dumpNodeEvents(ctx context.Context) error { }); err != nil { return err } - for k, v := range coallateEvents(filterTestEvents(el.Items, c.start)) { + for k, v := range collateEvents(filterTestEvents(el.Items, c.start)) { fmt.Print(getEventInformation(k, v)) } return nil @@ -103,7 +103,7 @@ func filterTestEvents(events []v1.Event, startTime time.Time) []v1.Event { }) } -func coallateEvents(events []v1.Event) map[v1.ObjectReference]*v1.EventList { +func collateEvents(events []v1.Event) map[v1.ObjectReference]*v1.EventList { eventMap := map[v1.ObjectReference]*v1.EventList{} for i := range events { elem := events[i]