Docker 1.1.0 發布

jopen 10年前發布 | 9K 次閱讀 Docker

Docker 是一個開源的應用容器引擎,讓開發者可以打包他們的應用以及依賴包到一個可移植的容器中,然后發布到任何流行的 Linux 機器上,也可以實現虛擬化。容器是完全使用沙箱機制,相互之間不會有任何接口(類似 iPhone 的 app)。幾乎沒有性能開銷,可以很容易地在機器和數據中心中運行。最重要的是,他們不依賴于任何語言、框架或包裝系統。

Docker 很高興的宣布 1.1.0 版本發布了,提升了整個 Docker 的生態系統,包括更新了 Docker 引擎、Docker Hub 和文檔。

Docker 1.1.0 值得關注的改進有:

新的 .dockerignore 功能

你可以添加一個 .dockerignore 文件到你的 `Dockerfile` , Docker 將會在發送構建上下文到守護進程時忽略在 .dockerignore 中指定的文件和目錄。

文件示例: https://github.com/dotcloud/docker/blob/master/.dockerignore

提交過程暫停容器

在一個運行中的容器中執行提交動作是不被推薦的,這會導致文件處于不一致的狀態。現在你可以在提交過程中暫停容器的運行。

你可以禁用該特性 docker commit --pause=false .

Tailing logs

支持查看容器日志的最新內容,例如查看最新 10 行的日志: docker logs --tail 10 . 你也可以使用 -f 參數來監控日志最新內容 docker logs --tail 0 -f .

其實這個特性跟 Linux 下的 tail 是差不多的

允許 tar 文件作為 Docker 構建的上下文

你可以傳遞給 docker build 一個 tar 文件來作為上下文,用于自動化 docker build 過程,例如: cat context.tar | docker build - or docker run builder_image | docker build -

在容器中綁定安裝整個文件系統

/ 現在允許作為 --volumes 的源。這意味著你可以在需要的時候綁定安裝你的整個文件系統。例如 docker run -v /:/my_host ubuntu:ro ls /my_host. 不過不允許安裝到 /.

其他方面的改進和變化

  • Port allocation has been improved. In the previous release, Docker could prevent you from starting a container with previously allocated ports which seemed to be in use when in fact they were not. This has been fixed.

  • A bug in docker save was introduced in the last release. The docker save command could produce images with invalid metadata. The command now produces images with correct metadata.

  • Running docker inspect in a container now returns which containers it is linked to.

  • The docker commit flag has improved validation, to better prevent you from committing an image with a name such as  -m. Image names with dashes in them potentially conflict with command line flags.

  • The API now has Improved status codes for  start and stop. Trying to start a running container will now return a 304 error.

  • Performance has been improved overall. Starting the daemon is faster than in previous releases. The daemon’s performance has also been improved when it is working with large numbers of images and containers.

  • Fixed an issue with white-spaces and multi-lines in Dockerfiles.

官方發行說明:http://blog.docker.com/2014/07/announcing-docker-1-1/

下載地址:https://github.com/dotcloud/docker/releases/tag/v1.1.0

Docker 1.1.0 發布

 本文由用戶 jopen 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
 轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
 本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!