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をまとめて落とす


docker ps -a | awk -F '  +' 'NR > 1 {print $7}' | xargs _docker_ rm -f

dockerコンテナ内からmacのlocalhostにアクセスしたいとき


host.docker.interna

特定のメソッドのみテスト


gradle test --tests "*HogeTest.testNewInstance" -i

特定のクラスのみテスト


gradle test --tests "*HogeTest" -i

コンテナを一括で消す


docker container list -qf name=zubatoku.*_<name> | xargs docker container rm -f

現在起動中のコンテナに関わるものはそのまま残したい場合


docker system prune -af --volumes

コンテナを全て消す


docker rm -f $(docker ps -aq)

コンテナイメージを全て消す


docker rmi -f $(docker images -q)

docker volumeを全て消す


docker volume rm -f $(docker volume ls -q)
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?