Skip to content

Commit

Permalink
docs: Various typo found by codespell
Browse files Browse the repository at this point in the history
Signed-off-by: Shengjing Zhu <[email protected]>
  • Loading branch information
zhsj committed Dec 22, 2020
1 parent b4c6046 commit 5988bfc
Show file tree
Hide file tree
Showing 21 changed files with 25 additions and 25 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ man: mandir $(addprefix man/,$(MANPAGES))
mandir:
@mkdir -p man

# Kept for backwards compatability
# Kept for backwards compatibility
genman: man/containerd.8 man/ctr.8

man/containerd.8: FORCE
Expand Down
4 changes: 2 additions & 2 deletions container_linux_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ func TestRegressionIssue4769(t *testing.T) {
select {
case et := <-eventStream:
if et.Event == nil {
t.Fatal(errors.Errorf("unexpect empty event: %+v", et))
t.Fatal(errors.Errorf("unexpected empty event: %+v", et))
}

v, err := typeurl.UnmarshalAny(et.Event)
Expand All @@ -133,7 +133,7 @@ func TestRegressionIssue4769(t *testing.T) {
}

if e, ok := v.(*apievents.TaskExit); !ok {
t.Fatal(errors.Errorf("unexpect event type: %+v", v))
t.Fatal(errors.Errorf("unexpected event type: %+v", v))
} else if e.ExitStatus != 0 {
t.Fatal(errors.Errorf("expect zero exit status, but got %v", e.ExitStatus))
}
Expand Down
2 changes: 1 addition & 1 deletion docs/man/containerd-config.toml.5.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ settings.

**imports**
: Imports is a list of additional configuration files to include.
This allows to split the main configuration file and keep some sections
This allows one to split the main configuration file and keep some sections
separately (for example vendors may keep a custom runtime configuration in a
separate file without modifying the main `config.toml`).
Imported files will overwrite simple fields like `int` or
Expand Down
4 changes: 2 additions & 2 deletions docs/remote-snapshotter.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ This is a containerd-defined label which contains ChainID that targets a committ
At this moment, user-defined labels (prefixed by `containerd.io/snapshot/`) will also be merged into the labels option.

```go
// Gets annotations appended to the targetting layer which would contain
// Gets annotations appended to the targeting layer which would contain
// snapshotter-specific information passed by the user.
labels := snapshots.FilterInheritedLabels(desc.Annotations)
if labels == nil {
Expand All @@ -98,7 +98,7 @@ labels["containerd.io/snapshot.ref"] = chainID
// snapshotter-specific information passed by the user.
opts := append(rCtx.SnapshotterOpts, snapshots.WithLabels(labels))

// Calls `Prepare` API with target indentifier and snapshotter-specific
// Calls `Prepare` API with target identifier and snapshotter-specific
// information.
mounts, err = sn.Prepare(ctx, key, parent.String(), opts...)
```
Expand Down
2 changes: 1 addition & 1 deletion images/image.go
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ func Platforms(ctx context.Context, provider content.Provider, image ocispec.Des
// If available is true, the caller can assume that required represents the
// complete set of content required for the image.
//
// missing will have the components that are part of required but not avaiiable
// missing will have the components that are part of required but not available
// in the provider.
//
// If there is a problem resolving content, an error will be returned.
Expand Down
2 changes: 1 addition & 1 deletion namespaces/ttrpc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ func TestCopyTTRPCMetadata(t *testing.T) {

func TestTTRPCNamespaceHeader(t *testing.T) {
ctx := context.Background()
namespace := "test-namepace"
namespace := "test-namespace"
ctx = withTTRPCNamespaceHeader(ctx, namespace)

header, ok := fromTTRPCHeader(ctx)
Expand Down
2 changes: 1 addition & 1 deletion pkg/cri/opts/spec_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ func WithDevices(osi osinterface.OS, config *runtime.ContainerConfig) oci.SpecOp
}
}

// WithCapabilities sets the provided capabilties from the security context
// WithCapabilities sets the provided capabilities from the security context
func WithCapabilities(sc *runtime.LinuxContainerSecurityContext) oci.SpecOpts {
capabilities := sc.GetCapabilities()
if capabilities == nil {
Expand Down
2 changes: 1 addition & 1 deletion pkg/cri/server/bandwidth/fake_shaper.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ import (
"k8s.io/apimachinery/pkg/api/resource"
)

// FakeShaper provides an implementation of the bandwith.Shaper.
// FakeShaper provides an implementation of the bandwidth.Shaper.
// Beware this is implementation has no features besides Reset and GetCIDRs.
type FakeShaper struct {
CIDRs []string
Expand Down
2 changes: 1 addition & 1 deletion pkg/cri/server/bandwidth/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func validateBandwidthIsReasonable(rsrc *resource.Quantity) error {
return fmt.Errorf("resource is unreasonably small (< 1kbit)")
}
if rsrc.Value() > maxRsrc.Value() {
return fmt.Errorf("resoruce is unreasonably large (> 1Pbit)")
return fmt.Errorf("resource is unreasonably large (> 1Pbit)")
}
return nil
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/cri/server/container_stats_list_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func (c *criService) containerMetrics(
}
}
default:
return &cs, errors.Errorf("unxpected metrics type: %v", metrics)
return &cs, errors.Errorf("unexpected metrics type: %v", metrics)
}
}

Expand Down
4 changes: 2 additions & 2 deletions pkg/cri/server/helpers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ func TestGetUserFromImage(t *testing.T) {
"empty user": {
user: "",
},
"multiple spearators": {
"multiple separators": {
user: "1:2:3",
uid: newI64(1),
},
Expand Down Expand Up @@ -99,7 +99,7 @@ func TestGetRepoDigestAndTag(t *testing.T) {
expectedRepoDigest: "",
expectedRepoTag: "gcr.io/library/busybox:latest",
},
"repo digest should not be empty if orignal ref is schema1 but has digest": {
"repo digest should not be empty if original ref is schema1 but has digest": {
ref: "gcr.io/library/busybox@sha256:e6693c20186f837fc393390135d8a598a96a833917917789d63766cab6c59594",
schema1: true,
expectedRepoDigest: "gcr.io/library/busybox@sha256:e6693c20186f837fc393390135d8a598a96a833917917789d63766cab6c59594",
Expand Down
4 changes: 2 additions & 2 deletions pkg/cri/server/restart.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ import (
// 2) Containerd containers may be deleted, but SHOULD NOT be added. Or else, recovery logic
// for the newly added container/sandbox will return error, because there is no corresponding root
// directory created.
// 3) Containerd container tasks may exit or be stoppped, deleted. Even though current logic could
// 3) Containerd container tasks may exit or be stopped, deleted. Even though current logic could
// tolerant tasks being created or started, we prefer that not to happen.

// recover recovers system state from containerd and status checkpoint.
Expand Down Expand Up @@ -264,7 +264,7 @@ func (c *criService) loadContainer(ctx context.Context, cntr containerd.Containe
return errors.Errorf("unexpected container state for created task: %q", status.State())
}
case containerd.Running:
// Task is running. Container must be in `RUNNING` state, based on our assuption that
// Task is running. Container must be in `RUNNING` state, based on our assumption that
// "task should not be started when containerd is down".
switch status.State() {
case runtime.ContainerState_CONTAINER_EXITED:
Expand Down
2 changes: 1 addition & 1 deletion pkg/cri/store/container/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ type StatusStorage interface {
// Delete the container status.
// Note:
// * Delete should be idempotent.
// * The status must be deleted in one trasaction.
// * The status must be deleted in one transaction.
Delete() error
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/netns/netns_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ func LoadNetNS(path string) *NetNS {
return &NetNS{path: path}
}

// Remove removes network namepace. Remove is idempotent, meaning it might
// Remove removes network namespace. Remove is idempotent, meaning it might
// be invoked multiple times and provides consistent result.
func (n *NetNS) Remove() error {
return unmountNS(n.path)
Expand Down
2 changes: 1 addition & 1 deletion pkg/netns/netns_other.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ func LoadNetNS(path string) *NetNS {
return &NetNS{path: path}
}

// Remove removes network namepace. Remove is idempotent, meaning it might
// Remove removes network namespace. Remove is idempotent, meaning it might
// be invoked multiple times and provides consistent result.
func (n *NetNS) Remove() error {
return errNotImplementedOnUnix
Expand Down
2 changes: 1 addition & 1 deletion pkg/netns/netns_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ func LoadNetNS(path string) *NetNS {
return &NetNS{path: path}
}

// Remove removes network namepace if it exists and not closed. Remove is idempotent,
// Remove removes network namespace if it exists and not closed. Remove is idempotent,
// meaning it might be invoked multiple times and provides consistent result.
func (n *NetNS) Remove() error {
hcnNamespace, err := hcn.GetNamespaceByID(n.path)
Expand Down
2 changes: 1 addition & 1 deletion remotes/docker/auth/fetch.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ func GenerateTokenOptions(ctx context.Context, host, username, secret string, c
return to, nil
}

// TokenOptions are optios for requesting a token
// TokenOptions are options for requesting a token
type TokenOptions struct {
Realm string
Service string
Expand Down
2 changes: 1 addition & 1 deletion remotes/docker/errcode.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ type ErrorDescriptor struct {
// keyed value when serializing api errors.
Value string

// Message is a short, human readable decription of the error condition
// Message is a short, human readable description of the error condition
// included in API responses.
Message string

Expand Down
2 changes: 1 addition & 1 deletion reports/2017-04-28.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ If are you looking for areas to contribute to containerd just take a pass throug

## containerd Summit Notes

Here are the notes from the containerd summit that was held after Dockercon. If there are important to you and you would like to start working on a feature, fix, request, please go ahead and open an issue on github. Just remember, we shouldn't have to have a summit to get things into containerd. Open issues, disscuss with other members of the community and write the code ;)
Here are the notes from the containerd summit that was held after Dockercon. If there are important to you and you would like to start working on a feature, fix, request, please go ahead and open an issue on github. Just remember, we shouldn't have to have a summit to get things into containerd. Open issues, discuss with other members of the community and write the code ;)

* “Since containerd is one of the bottom bricks in the stack, how can we setup automated integration tests for consumers of containerd?”
- Looking for others to provide compute (testing within Docker, K8s, Microsoft)
Expand Down
2 changes: 1 addition & 1 deletion snapshots/devmapper/snapshotter.go
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ func (s *Snapshotter) Commit(ctx context.Context, name, key string, opts ...snap
}

// After committed, the snapshot device will not be directly
// used anymore. We'd better deativate it to make it *invisible*
// used anymore. We'd better deactivate it to make it *invisible*
// in userspace, so that tools like LVM2 and fdisk cannot touch it,
// and avoid useless IOs on it.
//
Expand Down
2 changes: 1 addition & 1 deletion test/push.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ source $(dirname "${BASH_SOURCE[0]}")/utils.sh
DEPLOY_BUCKET=${DEPLOY_BUCKET:-"cri-containerd-staging"}
# DEPLOY_DIR is the directory in the gcs bucket to store the tarball.
DEPLOY_DIR=${DEPLOY_DIR:-""}
# BUILD_DIR is the directory of the bulid out.
# BUILD_DIR is the directory of the build out.
BUILD_DIR=${BUILD_DIR:-"_output"}
# TARBALL is the tarball name.
TARBALL=${TARBALL:-"cri-containerd.tar.gz"}
Expand Down

0 comments on commit 5988bfc

Please sign in to comment.