Skip to content

Commit c5ef8a2

Browse files
committed
fix(docs): fix duplicate instructions for windows installation
This commit fixes the duplicate copy and configure steps for the Windows powershell scripts. fixes containerd#9887 It also adds the architecture as a variable in preparation for the ARM64 support that is coming. Signed-off-by: Anthony Nandaa <[email protected]>
1 parent f0c64a9 commit c5ef8a2

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

docs/getting-started.md

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -107,24 +107,20 @@ To install containerd and its dependencies from the source, see [`BUILDING.md`](
107107

108108
## Installing containerd on Windows
109109

110-
From a PowerShell session run the following commands:
110+
From an elevated PowerShell session (_running as Admin_) run the following commands:
111111

112112
```PowerShell
113113
# If containerd previously installed run:
114114
Stop-Service containerd
115115
116116
# Download and extract desired containerd Windows binaries
117-
$Version="1.7.13" # update to your preferred version
118-
curl.exe -L https://github.com/containerd/containerd/releases/download/v$Version/containerd-$Version-windows-amd64.tar.gz -o containerd-windows-amd64.tar.gz
119-
tar.exe xvf .\containerd-windows-amd64.tar.gz
120-
121-
# Copy and configure
122-
Copy-Item -Path ".\bin" -Destination "$Env:ProgramFiles\containerd" -Recurse -Container:$false -Force
123-
cd $Env:ProgramFiles\containerd\
124-
.\containerd.exe config default | Out-File config.toml -Encoding ascii
117+
$Version="1.7.13" # update to your preferred version
118+
$Arch = "amd64" # arm64 also available
119+
curl.exe -LO https://github.com/containerd/containerd/releases/download/v$Version/containerd-$Version-windows-$Arch.tar.gz
120+
tar.exe xvf .\containerd-$Version-windows-amd64.tar.gz
125121
126122
# Copy
127-
Copy-Item -Path .\bin\* -Destination (New-Item -Type Directory $Env:ProgramFiles\containerd -Force) -Recurse -Force
123+
Copy-Item -Path .\bin -Destination $Env:ProgramFiles\containerd -Recurse -Force
128124
129125
# add the binaries (containerd.exe, ctr.exe) in $env:Path
130126
$Path = [Environment]::GetEnvironmentVariable("PATH", "Machine") + [IO.Path]::PathSeparator + "$Env:ProgramFiles\containerd"

0 commit comments

Comments
 (0)