官术网_书友最值得收藏!

Building a Docker image

Docker images are layered. The bottom layer is the operating system, which can be a full OS like Windows Server Core, or a minimal OS like Microsoft Nano Server. On top of that are layers for each change you make to the base OS when you build an image - by installing software, copying files, and running commands. Logically, Docker treats the image as a single unit, but physically, each layer is stored as a separate file in Docker's cache, so images with a lot of common features can share layers from the cache.

Images are built using a text file with the Dockerfile language - specifying the base OS image to start with, and all the steps to add on top. The language is very simple, and there are only a few commands you need to master in order to build production-grade images. I'll start by looking at the basic PowerShell image I've been using so far in this chapter.

主站蜘蛛池模板: 伊金霍洛旗| 左云县| 忻城县| 山阳县| 长宁县| 伊金霍洛旗| 许昌县| 顺平县| 丹江口市| 葫芦岛市| 百色市| 张家港市| 富平县| 武义县| 甘泉县| 合肥市| 新乡县| 锦屏县| 东港市| 雷山县| 淳化县| 顺义区| 浦东新区| 宜都市| 开平市| 康保县| 旬邑县| 甘孜| 永吉县| 高清| 社会| 连南| 广平县| 平山县| 黔西县| 喜德县| 五华县| 陈巴尔虎旗| 饶阳县| 郴州市| 巩留县|