설명
하나 이상의 이미지 제거
사용법
$ docker rmi [OPTIONS] IMAGE [IMAGE...]
Bash
복사
옵션
Option | Short | Default | Description |
--force | -f | 이미지 강제 삭제 | |
--no-prune | 태그가 지정되지 않은 부모를 삭제하지 마십시오 |
예시
$ docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
test1 latest fd484f19954f 23 seconds ago 7 B (virtual 4.964 MB)
test latest fd484f19954f 23 seconds ago 7 B (virtual 4.964 MB)
test2 latest fd484f19954f 23 seconds ago 7 B (virtual 4.964 MB)
docker rmi fd484f19954f
Error: Conflict, cannot delete image fd484f19954f because it is tagged in multiple repositories, use -f to force
2013/12/11 05:47:16 Error: failed to remove one or more images
docker rmi test1:latest
Untagged: test1:latest
docker rmi test2:latest
Untagged: test2:latest
docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
test latest fd484f19954f 23 seconds ago 7 B (virtual 4.964 MB)
docker rmi test:latest
Untagged: test:latest
Deleted: fd484f19954f4920da7ff372b5067f5b7ddb2fd3830cecd17b96ea9e286ba5b8
Bash
복사