0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

Dockerインストール【CentOS8】

Posted at

Docker インストール

何番煎じでもいい
これはメモなんだ、、、

公式手順

  • 気を付ける点
    • usermod コマンド で 一般ユーザでdockerコマンドを使えるようにする
    • ↑の変更後、いったんログアウトしないと設定反映されない

リポジトリセットアップ

# sudo dnf -y install yum-utils

$ sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

インストール

$ sudo dnf install docker-ce docker-ce-cli containerd.io

起動

$ sudo systemctl start docker
$ sudo systemctl status docker
● docker.service - Docker Application Container Engine
   Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)
   Active: active (running) since Fri 2021-12-03 06:16:34 UTC; 20s ago

Hello-world確認

$ sudo usermod -aG docker $USER
→いったんログアウト
$ docker run hello-world
Hello from Docker!
This message shows that your installation appears to be working correctly.
0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?