0
0

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基本コマンド

Posted at

Dockerの基本的な流れ

アプリコード
Dockerfile

↓作成

イメージ

↓作成・起動

コンテナ

↓停止
↓削除

コマンド

  • イメージを作成
docker image build
  • イメージが作成できたかの確認
docker image ls
  • dockerコマンド一覧
docker --help
  • コンテナの作成・起動
docker container run
docker container run -d (バックグラウンドで実行される)
  • コンテナの起動状態の確認
docker container ls
docker container ls -a
  • コンテナの停止
docker container stop
  • コンテナの削除
docker container rm
  • ログの確認
docker container logs
  • 実行中のコンテナで別のコマンドを使う
docker container exec
  • 後片付け
docker system prune -a
0
0
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
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?