Windows 2025
Sponsored Link

Docker : インストール2024/12/16

 

コンテナー型仮想化ツール Docker をインストールして、Windows Container が利用できるよう設定します。

[1] PowerShell を管理者権限で起動してインストールします。
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.

# コンテナー機能インストール
# インストール後 [Y] で再起動
PS C:\Users\Administrator> Enable-WindowsOptionalFeature -Online -FeatureName Containers 
Do you want to restart the computer to complete this operation now?
[Y] Yes  [N] No  [?] Help (default is "Y"): Y

# 再起動後 Docker インストール
PS C:\Users\Administrator> Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/microsoft/Windows-Containers/Main/helpful_tools/Install-DockerCE/install-docker-ce.ps1" -o install-docker-ce.ps1 
PS C:\Users\Administrator> .\install-docker-ce.ps1 
Querying status of Windows feature: Containers...
Feature Containers is already enabled.
DOCKER default
Checking Docker versions
Downloading https://download.docker.com/win/static/stable/x86_64/docker-27.4.0.zip to C:\Users\Administrator\DockerDownloads\docker-27.4.0.zip
Installing Docker... C:\Users\Administrator\DockerDownloads\docker-27.4.0\docker\docker.exe
Installing Docker daemon... C:\Users\Administrator\DockerDownloads\docker-27.4.0\docker\dockerd.exe
Configuring the docker service...
Waiting for Docker daemon...
Successfully connected to Docker Daemon.
The following images are present on this machine:
REPOSITORY   TAG       IMAGE ID   CREATED   SIZE

Script complete!

# 確認
PS C:\Users\Administrator> docker version 
Client:
 Version:           27.4.0
 API version:       1.47
 Go version:        go1.22.10
 Git commit:        bde2b89
 Built:             Sat Dec  7 10:40:21 2024
 OS/Arch:           windows/amd64
 Context:           default

Server: Docker Engine - Community
 Engine:
  Version:          27.4.0
  API version:      1.47 (minimum version 1.24)
  Go version:       go1.22.10
  Git commit:       92a8393
  Built:            Sat Dec  7 10:39:14 2024
  OS/Arch:          windows/amd64
  Experimental:     false
関連コンテンツ