/
Docker インストール (Windows - WSL2 / Ubuntu)

Docker インストール (Windows - WSL2 / Ubuntu)

本ドキュメントは Windows に WSL2 をインストールして Linux(Ubuntu)環境を構築する場合の Docker インストール手順です。


目次


前提

Windows 10 バージョン 2004 以降である必要があります。確認方法は以下の手順をご参照ください。



インストール手順

Docker をインストールする

  1. コマンドプロンプトを管理者権限で開きます。


  2. 以下のコマンドを実行して WSL をインストールします。

    > wsl --install
  3. 以下のコマンドを実行し、WSL がインストールされていることを確認します。

    > wsl --status	
    実行結果例
    既定の配布: Ubuntu
    既定のバージョン: 2
  4. WSL2 のコンソールを起動します。

    > wsl
  5. Docker のインストールを準備します。

    $ sudo apt-get update
    $ sudo apt-get install \
        apt-transport-https \
        ca-certificates \
        curl \
        gnupg \
        lsb-release
    $  curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
    $  echo \
      "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \
      $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
  6. Docker をインストールします。

    $ sudo apt-get update
    $ sudo apt-get install docker-ce docker-ce-cli containerd.io
  7. WSL2 環境のコンソールを開き、Docker が使用できることを確認します。

  8. $ docker --version
    実行結果例
    Docker version 20.10.7, build f0df350



docker-compose をインストールする

Docker インストール (Amazon Linux 2) の docker-compose をインストールする 手順を参考にインストールしてください。





Related content

Cadre スタートガイド
Cadre スタートガイド
Read with this
Docker インストール (Windows - Docker Desktop for Windows)
Docker インストール (Windows - Docker Desktop for Windows)
More like this
Cadre 動作環境
Cadre 動作環境
Read with this
Docker インストール (Amazon Linux 2)
Docker インストール (Amazon Linux 2)
More like this
Cadre インストール (Windows)
Cadre インストール (Windows)
More like this

リックソフト株式会社 は、日本でトップレベルのAtlassian Platinum Solution Partnerです。
大規模ユーザーへの対応実績が認められたEnterpriseの認定をうけ、高度なトレーニング要件をクリアし、小規模から大規模のお客様まで対応可能な実績を示したパートナー企業です。


Copyright © Ricksoft Co., Ltd. プライバシーポリシー お問い合わせ