Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(docs): update installation steps for windows and linux #2112

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 28 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,16 +134,20 @@ In addition to containerd, the following components should be installed:

These dependencies are included in `nerdctl-full-<VERSION>-<OS>-<ARCH>.tar.gz`, but not included in `nerdctl-<VERSION>-<OS>-<ARCH>.tar.gz`.

### Brew
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why remove?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just renamed to Linux the other items are based on the OS types instead, i.e. Windows, FreeBSD, MacOS.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks like we lost the On Linux systems you can install nerdctl via [brew](https://brew.sh): below?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jsturtevant -- I've replaced that with the standard installation process on Linux. I don't see a reason to install brew first so that you can install nerdctl when most likely they have already installed containerd, etc. using the standard process of getting the binaries from Github with curl.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should keep brew install instructions and we can add the additional manual process. Then the user can choose what is best for them.

### Linux

On Linux systems you can install nerdctl via [brew](https://brew.sh):
Download the `nerdctl-<VERSION>-<OS>-<ARCH>.tar.gz` archive from https://github.com/containerd/nerdctl/releases,verify its sha256sum, and extract it under `/usr/local/bin`:

```bash
brew install nerdctl
$ version="1.2.1" # update to your version of choice
$ curl -L https://github.com/containerd/nerdctl/releases/download/v$version/nerdctl-$version-linux-amd64.tar.gz
$ sudo tar Cxzvf /usr/local/bin nerdctl-$version-linux-amd64.tar.gz
nerdctl
containerd-rootless-setuptool.sh
containerd-rootless.sh
$ nerdctl --version
```

This is currently not supported for macOS. The section below shows how to install on macOS using brew.

### macOS

[Lima](https://github.com/lima-vm/lima) project provides Linux virtual machines for macOS, with built-in integration for nerdctl.
Expand All @@ -154,14 +158,28 @@ $ limactl start
$ lima nerdctl run -d --name nginx -p 127.0.0.1:8080:80 nginx:alpine
```

### FreeBSD
### Windows

See [`./docs/freebsd.md`](docs/freebsd.md).
Currently, there is experimental support for Windows (see below for features that are currently known to work).

### Windows
To set up on Windows, first make sure you have [installed `containerd`](https://github.com/containerd/containerd/blob/main/docs/getting-started.md#installing-containerd-on-windows) then run the following in PowerShell:

```powershell
$Version="1.2.1" # update to your version of choice
# the following is based on amd64, for other architectures, see release page
curl.exe -L https://github.com/containerd/nerdctl/releases/download/v$Version/nerdctl-$Version-windows-amd64.tar.gz -o nerdctl-$Version-windows-amd64.tar.gz
tar.exe xvf nerdctl-$Version-windows-amd64.tar.gz
Copy-Item .\nerdctl.exe $Env:ProgramFiles\containerd -Force
```
If you already added `$Env:ProgramFiles\containerd` in the `PATH`, you should have `nerdctl` accessible from anywhere now:

```powershell
nerdctl --version
```

- Linux containers: Known to work on WSL2
- Windows containers: experimental support for Windows (see below for features that are currently known to work)
### FreeBSD

See [`./docs/freebsd.md`](docs/freebsd.md).

### Docker

Expand Down