浏览代码

Remove volumes on docker run -rm

If we don't care about the container then we don't care about any
volumes created with the run of that container

Docker-DCO-1.1-Signed-off-by: Michael Crosby <michael@crosbymichael.com> (github: crosbymichael)
Michael Crosby 11 年之前
父节点
当前提交
14acf6883d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      commands.go

+ 1 - 1
commands.go

@@ -2138,7 +2138,7 @@ func (cli *DockerCli) CmdRun(args ...string) error {
 		if _, status, err = getExitCode(cli, runResult.ID); err != nil {
 			return err
 		}
-		if _, _, err := cli.call("DELETE", "/containers/"+runResult.ID, nil); err != nil {
+		if _, _, err := cli.call("DELETE", "/containers/"+runResult.ID+"?v=1", nil); err != nil {
 			return err
 		}
 	} else {