diff --git a/.github/ISSUE_TEMPLATE/bug_report.yaml b/.github/ISSUE_TEMPLATE/bug_report.yaml index 712d9aece38..ed0a886f9d3 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yaml +++ b/.github/ISSUE_TEMPLATE/bug_report.yaml @@ -10,7 +10,7 @@ body: repository. If there is a duplicate, please close your issue and add a comment to the existing issue instead. - Please also see [the FAQs and Troubleshooting](https://github.com/containerd/nerdctl/blob/master/docs/faq.md). + Please also see [the FAQs and Troubleshooting](https://github.com/containerd/nerdctl/blob/main/docs/faq.md). - type: textarea attributes: diff --git a/.github/workflows/ghcr-image-build-and-publish.yml b/.github/workflows/ghcr-image-build-and-publish.yml index 18f0074efbe..e7f101a17bb 100644 --- a/.github/workflows/ghcr-image-build-and-publish.yml +++ b/.github/workflows/ghcr-image-build-and-publish.yml @@ -7,7 +7,7 @@ name: Container Image Build on: push: - branches: [ master, main ] + branches: [ main ] # Publish semver tags as releases. tags: [ 'v*.*.*' ] diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index d98fb09c537..93c28cef877 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -3,7 +3,6 @@ name: test on: push: branches: - - master - main - 'release/**' pull_request: diff --git a/README.md b/README.md index 5277bca06a3..be839404885 100644 --- a/README.md +++ b/README.md @@ -177,7 +177,7 @@ Trivial: ## Similar tools -- [`ctr`](https://github.com/containerd/containerd/tree/master/cmd/ctr): incompatible with Docker CLI, and not friendly to users. +- [`ctr`](https://github.com/containerd/containerd/tree/main/cmd/ctr): incompatible with Docker CLI, and not friendly to users. Notably, `ctr` lacks the equivalents of the following nerdctl commands: - `nerdctl run -p ` - `nerdctl run --restart=always --net=bridge` @@ -194,9 +194,9 @@ Trivial: ## Developer guide nerdctl is a containerd **non-core** sub-project, licensed under the [Apache 2.0 license](./LICENSE). As a containerd non-core sub-project, you will find the: - * [Project governance](https://github.com/containerd/project/blob/master/GOVERNANCE.md), + * [Project governance](https://github.com/containerd/project/blob/main/GOVERNANCE.md), * [Maintainers](./MAINTAINERS), - * and [Contributing guidelines](https://github.com/containerd/project/blob/master/CONTRIBUTING.md) + * and [Contributing guidelines](https://github.com/containerd/project/blob/main/CONTRIBUTING.md) information in our [`containerd/project`](https://github.com/containerd/project) repository. diff --git a/cmd/nerdctl/client.go b/cmd/nerdctl/client.go index 6d23b3ba89d..ea7f90e26ac 100644 --- a/cmd/nerdctl/client.go +++ b/cmd/nerdctl/client.go @@ -68,7 +68,7 @@ func newClient(cmd *cobra.Command, opts ...containerd.ClientOpt) (*containerd.Cl func newClientWithPlatform(cmd *cobra.Command, platform string, clientOpts ...containerd.ClientOpt) (*containerd.Client, context.Context, context.CancelFunc, error) { if platform != "" { if canExec, canExecErr := platformutil.CanExecProbably(platform); !canExec { - warn := fmt.Sprintf("Platform %q seems incompatible with the host platform %q. If you see \"exec format error\", see https://github.com/containerd/nerdctl/blob/master/docs/multi-platform.md", + warn := fmt.Sprintf("Platform %q seems incompatible with the host platform %q. If you see \"exec format error\", see https://github.com/containerd/nerdctl/blob/main/docs/multi-platform.md", platform, platforms.DefaultString()) if canExecErr != nil { logrus.WithError(canExecErr).Warn(warn) diff --git a/cmd/nerdctl/create.go b/cmd/nerdctl/create.go index d92cec9ea45..ac712c113cc 100644 --- a/cmd/nerdctl/create.go +++ b/cmd/nerdctl/create.go @@ -32,7 +32,7 @@ func newCreateCommand() *cobra.Command { longHelp += "WARNING: `nerdctl create` is experimental on Windows and currently broken (https://github.com/containerd/nerdctl/issues/28)" case "freebsd": longHelp += "\n" - longHelp += "WARNING: `nerdctl create` is experimental on FreeBSD and currently requires `--net=none` (https://github.com/containerd/nerdctl/blob/master/docs/freebsd.md)" + longHelp += "WARNING: `nerdctl create` is experimental on FreeBSD and currently requires `--net=none` (https://github.com/containerd/nerdctl/blob/main/docs/freebsd.md)" } var createCommand = &cobra.Command{ Use: "create [flags] IMAGE [COMMAND] [ARG...]", diff --git a/cmd/nerdctl/image_encrypt.go b/cmd/nerdctl/image_encrypt.go index 4758893603e..39ee30659f3 100644 --- a/cmd/nerdctl/image_encrypt.go +++ b/cmd/nerdctl/image_encrypt.go @@ -39,7 +39,7 @@ Example: nerdctl push example.com/foo:encrypted To run the encrypted image, put the private key file (mykey.pem) to /etc/containerd/ocicrypt/keys (rootful) or ~/.config/containerd/ocicrypt/keys (rootless). -containerd before v1.4 requires extra configuration steps, see https://github.com/containerd/nerdctl/blob/master/docs/ocicrypt.md +containerd before v1.4 requires extra configuration steps, see https://github.com/containerd/nerdctl/blob/main/docs/ocicrypt.md CAUTION: This command only encrypts image layers, but does NOT encrypt container configuration such as 'Env' and 'Cmd'. To see non-encrypted information, run 'nerdctl image inspect --mode=native --platform=PLATFORM example.com/foo:encrypted' . diff --git a/cmd/nerdctl/ipfs_registry_serve.go b/cmd/nerdctl/ipfs_registry_serve.go index f2ee91ff47d..51214d10fbf 100644 --- a/cmd/nerdctl/ipfs_registry_serve.go +++ b/cmd/nerdctl/ipfs_registry_serve.go @@ -80,7 +80,7 @@ func ipfsRegistryServeAction(cmd *cobra.Command, args []string) error { } else { ipfsClient, err = httpapi.NewLocalApi() if err != nil { - return fmt.Errorf("error encountered, '%w', Please setup ipfs daemon, see https://github.com/containerd/nerdctl/blob/master/docs/ipfs.md", err) + return fmt.Errorf("error encountered, '%w', Please setup ipfs daemon, see https://github.com/containerd/nerdctl/blob/main/docs/ipfs.md", err) } } h, err := ipfs.NewRegistry(ipfsClient, ipfs.RegistryOptions{ diff --git a/cmd/nerdctl/main.go b/cmd/nerdctl/main.go index b8f6ea2077b..dc2a0b86142 100644 --- a/cmd/nerdctl/main.go +++ b/cmd/nerdctl/main.go @@ -197,8 +197,8 @@ func initRootCmdFlags(rootCmd *cobra.Command, tomlPath string) (*pflag.FlagSet, rootCmd.PersistentFlags().Bool("insecure-registry", cfg.InsecureRegistry, "skips verifying HTTPS certs, and allows falling back to plain HTTP") // hosts-dir is defined as StringSlice, not StringArray, to allow specifying "--hosts-dir=/etc/containerd/certs.d,/etc/docker/certs.d" rootCmd.PersistentFlags().StringSlice("hosts-dir", cfg.HostsDir, "A directory that contains /hosts.toml (containerd style) or /{ca.cert, cert.pem, key.pem} (docker style)") - // Experimental enable experimental feature, see in https://github.com/containerd/nerdctl/blob/master/docs/experimental.md - AddPersistentBoolFlag(rootCmd, "experimental", nil, nil, cfg.Experimental, "NERDCTL_EXPERIMENTAL", "Control experimental: https://github.com/containerd/nerdctl/blob/master/docs/experimental.md") + // Experimental enable experimental feature, see in https://github.com/containerd/nerdctl/blob/main/docs/experimental.md + AddPersistentBoolFlag(rootCmd, "experimental", nil, nil, cfg.Experimental, "NERDCTL_EXPERIMENTAL", "Control experimental: https://github.com/containerd/nerdctl/blob/main/docs/experimental.md") return aliasToBeInherited, nil } @@ -440,7 +440,7 @@ func AddStringFlag(cmd *cobra.Command, name string, aliases []string, value stri } // AddPersistentStringFlag is similar to AddStringFlag but persistent. -// See https://github.com/spf13/cobra/blob/master/user_guide.md#persistent-flags to learn what is "persistent". +// See https://github.com/spf13/cobra/blob/main/user_guide.md#persistent-flags to learn what is "persistent". func AddPersistentStringFlag(cmd *cobra.Command, name string, aliases, localAliases, persistentAliases []string, aliasToBeInherited *pflag.FlagSet, value string, env, usage string) { if env != "" { usage = fmt.Sprintf("%s [$%s]", usage, env) @@ -491,7 +491,7 @@ func AddPersistentStringFlag(cmd *cobra.Command, name string, aliases, localAlia } // AddPersistentBoolFlag is similar to AddBoolFlag but persistent. -// See https://github.com/spf13/cobra/blob/master/user_guide.md#persistent-flags to learn what is "persistent". +// See https://github.com/spf13/cobra/blob/main/user_guide.md#persistent-flags to learn what is "persistent". func AddPersistentBoolFlag(cmd *cobra.Command, name string, aliases, nonPersistentAliases []string, value bool, env, usage string) { if env != "" { usage = fmt.Sprintf("%s [$%s]", usage, env) @@ -528,7 +528,7 @@ func AddPersistentBoolFlag(cmd *cobra.Command, name string, aliases, nonPersiste } // AddPersistentStringArrayFlag is similar to cmd.Flags().StringArray but supports aliases and env var and persistent. -// See https://github.com/spf13/cobra/blob/master/user_guide.md#persistent-flags to learn what is "persistent". +// See https://github.com/spf13/cobra/blob/main/user_guide.md#persistent-flags to learn what is "persistent". func AddPersistentStringArrayFlag(cmd *cobra.Command, name string, aliases, nonPersistentAliases []string, value []string, env string, usage string) { if env != "" { usage = fmt.Sprintf("%s [$%s]", usage, env) diff --git a/cmd/nerdctl/run.go b/cmd/nerdctl/run.go index bf439655fde..3647f5a0326 100644 --- a/cmd/nerdctl/run.go +++ b/cmd/nerdctl/run.go @@ -72,7 +72,7 @@ func newRunCommand() *cobra.Command { longHelp += "WARNING: `nerdctl run` is experimental on Windows and currently broken (https://github.com/containerd/nerdctl/issues/28)" case "freebsd": longHelp += "\n" - longHelp += "WARNING: `nerdctl run` is experimental on FreeBSD and currently requires `--net=none` (https://github.com/containerd/nerdctl/blob/master/docs/freebsd.md)" + longHelp += "WARNING: `nerdctl run` is experimental on FreeBSD and currently requires `--net=none` (https://github.com/containerd/nerdctl/blob/main/docs/freebsd.md)" } var runCommand = &cobra.Command{ Use: "run [flags] IMAGE [COMMAND] [ARG...]", diff --git a/docs/faq.md b/docs/faq.md index 57d6fb33d74..5b4d44d3bba 100644 --- a/docs/faq.md +++ b/docs/faq.md @@ -48,7 +48,7 @@ Note that competing with Docker is _not_ the goal of nerdctl. Those cutting-edge ### How is nerdctl different from `ctr` and `crictl` ? -[`ctr`](https://github.com/containerd/containerd/tree/master/cmd/ctr) is a debugging utility bundled with containerd. +[`ctr`](https://github.com/containerd/containerd/tree/main/cmd/ctr) is a debugging utility bundled with containerd. ctr is incompatible with Docker CLI, and not friendly to users. diff --git a/docs/rootless.md b/docs/rootless.md index 141d460e367..4c9cfa5d4b1 100644 --- a/docs/rootless.md +++ b/docs/rootless.md @@ -102,7 +102,7 @@ $ export CONTAINERD_SNAPSHOTTER=stargz $ nerdctl run -it --rm ghcr.io/stargz-containers/alpine:3.10.2-esgz ``` -See https://github.com/containerd/stargz-snapshotter/blob/master/docs/pre-converted-images.md for the image list. +See https://github.com/containerd/stargz-snapshotter/blob/main/docs/pre-converted-images.md for the image list. ## bypass4netns | :zap: Requirement | nerdctl >= 0.17 | diff --git a/docs/stargz.md b/docs/stargz.md index b3d4222d5ef..8bf3b2e278d 100644 --- a/docs/stargz.md +++ b/docs/stargz.md @@ -31,7 +31,7 @@ See https://github.com/containerd/stargz-snapshotter to learn further informatio # nerdctl --snapshotter=stargz run -it --rm ghcr.io/stargz-containers/fedora:30-esgz ``` -For the list of pre-converted Stargz images, see https://github.com/containerd/stargz-snapshotter/blob/master/docs/pre-converted-images.md +For the list of pre-converted Stargz images, see https://github.com/containerd/stargz-snapshotter/blob/main/docs/pre-converted-images.md ### Benchmark result (Dec 9, 2020) For running `python3 -c print("hi")`, eStargz with Stargz Snapshotter is 3-4 times faster than the legacy OCI with overlayfs snapshotter.