- Deployment with Docker
- Srdjan Grubor
- 200字
- 2021-07-02 23:22:13
Labels
Our first new directive here is LABEL:
LABEL version="1.0"
LABEL org.sgnn7.name="python-webserver"
LABEL <key>=<value> or LABEL <key> <value> is used to add metadata about the image that is being built, which can later be examined and filtered by docker ps and docker images using something like docker images --filter "<key>=<value>". Keys are generally all lowercase in the reverse-dns notation, but you can use anything you want here and version should be present on every image, so we use the top-level version key name. However, the version here is not only there so that we can filter images but also to break Docker's cache if we change it. Without cache-busting of this sort or through the manually set flag during builds ( docker build --no-cache ), Docker will keep reusing the cache all the way up to the most recently changed directive or files so there is a high probability that your container will stay stuck in a frozen package configuration. This condition may or may not be what you want, but just in case you have automated build tooling, adding a version layer that can break the cache whenever you change it makes the container very easy to update.
- Hands-On Intelligent Agents with OpenAI Gym
- Getting Started with Clickteam Fusion
- 基于LabWindows/CVI的虛擬儀器設計與應用
- 數據庫原理與應用技術
- Windows游戲程序設計基礎
- 計算機網絡安全
- 電氣控制與PLC技術應用
- Learning Azure Cosmos DB
- 學會VBA,菜鳥也高飛!
- 網絡安全技術及應用
- TensorFlow Reinforcement Learning Quick Start Guide
- Excel 2007常見技法與行業應用實例精講
- 人工智能:語言智能處理
- 學練一本通:51單片機應用技術
- 21天學通Linux嵌入式開發