https://kumu.io/trucojuegos/nuevo-generador-de-seguidores-en-tiktok-gratis-para-ios-y-android https://kumu.io/trucojuegos/1000-seguidores-en-tiktok-gratis-para-ios-y-android-asd98s9dffdhgfh https://kumu.io/diamantesfreefire/diamantes-para-free-fire-gratis-rapido-y-real-2025-apk https://kumu.io/diamantesfreefire/como-se-gana-diamantes-gratis-free-fire-para-ios-y-android-2025 https://kumu.io/diamantesfreefire/real5600-diamantes-free-fire-gratis-hack-ios-y-android https://kumu.io/diamantesfreefire/real-diamantes-gratis-free-fire-hack-para-ios-y-android-max https://nothingbuttop10.bandcamp.com/album/kumu-descargar-free-fire-max-9999 https://hackmd.io/@b5KLTCE3RViedJhnKQZl-Q/BkXRYaSPlg https://lichess.org/team/nuevo-1000-seguidores-en-tiktok-gratis-para-ios-y-android https://lichess.org/team/nuevo-generador-de-seguidores-en-tiktok-gratis-ios-android https://lichess.org/team/metodo-5600-diamantes-free-fire-gratis-para-ios-y-android https://lichess.org/team/approved-cod-mobile-free-cp-ios--android-no-verification https://lichess.org/team/latest-free-cod-mobile-cp-for-ios--android-unlimited https://lichess.org/team/claimcp-free--cod-mobile-free-cp-ios-android https://nothingbuttop10.bandcamp.com/album/lichess-cod-mobile-cp https://linktr.ee/diamanten_gratis_chapters https://reach.link/gratis-diamanten-bei-chapters https://kumu.io/gratisdiamantenbeichapters/neueste-gratis-diamanten-bei-chapters-hack-auf-deutsch-ios-android https://kumu.io/gratisdiamantenbeichapters/unendlich-diamanten-bei-chapters-cheats-auf-deutsch https://www.weareplaystation.fr/communautes/jeux-independants/astuces/wiki/nouveau-liens-des-gratuits-monopoly-go-ios-android-du-juillet-29-2025 https://www.weareplaystation.fr/communautes/jeux-independants/astuces/wiki/astuce-monopoly-go-triche-generateur-de-des-gratuit-pour-ios-et-android-en-ligne-99sdf https://nothingbuttop10.bandcamp.com/album/9999-links-lets-go https://aetherhub.com/Tourney/RoundTourney/67327 https://aetherhub.com/Tourney/RoundTourney/67333 https://aetherhub.com/Tourney/RoundTourney/67334 https://aetherhub.com/Tourney/RoundTourney/67335 https://aetherhub.com/Tourney/RoundTourney/67336 https://aetherhub.com/Tourney/RoundTourney/67337 https://aetherhub.com/Tourney/RoundTourney/67338 https://aetherhub.com/Tourney/RoundTourney/67339 https://aetherhub.com/Tourney/RoundTourney/67340 https://aetherhub.com/Tourney/RoundTourney/67341 https://nothingbuttop10.bandcamp.com/album/tik-ff-outbound-links https://aetherhub.com/Tourney/RoundTourney/67640 https://aetherhub.com/Tourney/RoundTourney/67654 https://aetherhub.com/Tourney/RoundTourney/67655 https://aetherhub.com/Tourney/RoundTourney/67656 https://aetherhub.com/Tourney/RoundTourney/67657 https://aetherhub.com/Tourney/RoundTourney/67658 https://aetherhub.com/Tourney/RoundTourney/67659 https://aetherhub.com/Tourney/RoundTourney/67660 https://aetherhub.com/Tourney/RoundTourney/67661 https://aetherhub.com/Tourney/RoundTourney/67663 https://aetherhub.com/Tourney/RoundTourney/67669 https://aetherhub.com/Tourney/RoundTourney/67673 https://aetherhub.com/Tourney/RoundTourney/67640/?generator9 https://aetherhub.com/Tourney/RoundTourney/67654/?generator8 https://aetherhub.com/Tourney/RoundTourney/67655/?generator7 https://aetherhub.com/Tourney/RoundTourney/67656/?generator6 https://aetherhub.com/Tourney/RoundTourney/67657/?generator5 https://aetherhub.com/Tourney/RoundTourney/67658/?generator4 https://aetherhub.com/Tourney/RoundTourney/67659/?generator3 https://aetherhub.com/Tourney/RoundTourney/67660/?generator2 https://aetherhub.com/Tourney/RoundTourney/67661/?generator1 https://aetherhub.com/Tourney/RoundTourney/67663/?generator22 https://aetherhub.com/Tourney/RoundTourney/67669/?generator11 https://aetherhub.com/Tourney/RoundTourney/67673/?generator33 https://nothingbuttop10.bandcamp.com/album/aether-bonus-obl-999 https://paddling.com/paddle/trips/greatness-pubg-mobile-free-uc-bp-for-ios-android-pubg-mobile-unlimited-uc-generator-999k https://paddling.com/paddle/trips/yes-clash-of-clans-free-gems-ios-android-clash-of-clans-unlimited-gems-generator-updated-999k https://paddling.com/paddle/trips/wow-stumble-guys-free-gems-ios-android-stumble-guys-free-gems-generator-updated-999k https://paddling.com/paddle/trips/glitch-brawl-stars-free-gems-ios-android-brawl-stars-unlimited-gems-generator-updated-9999k https://paddling.com/paddle/trips/claim-apex-legends-free-coins-ios-android-apex-legends-coins-generator-updated-9999k https://paddling.com/paddle/trips/approved-dragon-city-free-gems-ios-android-dragon-city-unlimited-gems-updated-cheats https://paddling.com/paddle/trips/latest-bigo-live-free-diamonds-ios-android-bigo-live-diamonds-generator-unlimited-beans https://paddling.com/paddle/trips/greatness-pubg-mobile-free-uc-bp-for-ios-android-pubg-mobile-unlimited-uc-generator-999k/?adr https://paddling.com/paddle/trips/yes-clash-of-clans-free-gems-ios-android-clash-of-clans-unlimited-gems-generator-updated-999k/?wdf https://paddling.com/paddle/trips/wow-stumble-guys-free-gems-ios-android-stumble-guys-free-gems-generator-updated-999k/?asdc https://paddling.com/paddle/trips/glitch-brawl-stars-free-gems-ios-android-brawl-stars-unlimited-gems-generator-updated-9999k/?dwuq https://paddling.com/paddle/trips/claim-apex-legends-free-coins-ios-android-apex-legends-coins-generator-updated-9999k/?dfur https://paddling.com/paddle/trips/approved-dragon-city-free-gems-ios-android-dragon-city-unlimited-gems-updated-cheats/?sdfi https://paddling.com/paddle/trips/latest-bigo-live-free-diamonds-ios-android-bigo-live-diamonds-generator-unlimited-beans/?asfiu https://nothingbuttop10.bandcamp.com/album/latest-paddling-outbound-links

Sat. Aug 2nd, 2025
Docker Görüntü Katmanları Nelerdir?

Docker görüntüleri, kapsayıcılarınızda gördüğünüz içeriği toplu olarak sağlayan birden çok katmandan oluşur. Ancak gerçekte katman nedir ve tam bir görüntüden farkı nedir?

Bu makalede, bu iki kavramı nasıl ayırt edeceğinizi ve farkın neden önemli olduğunu öğreneceksiniz. Katmanları tam olarak anlamadan Docker’ı kullanabilirsiniz, ancak bunların amaçlarının farkında olmak, optimizasyon fırsatlarını belirlemenize yardımcı olacaktır.

Resim Nedir?

Bir Docker “görüntüsü”, tutarlı kapların oluşturulabileceği bir şablon gibi davranır. Docker geleneksel bir sanal makine olsaydı, görüntü sanal makinenizi kurmak için kullanılan ISO’ya benzetilebilirdi. Docker, hem konsept hem de uygulama açısından VM’lerden farklı olduğu için bu sağlam bir karşılaştırma değildir, ancak yine de faydalı bir başlangıç ​​noktasıdır.

Görüntüler, yeni kapsayıcıların ilk dosya sistemi durumunu tanımlar. Uygulamanızın kaynak kodunu ve bağımlılıklarını bir kapsayıcı çalışma zamanı ile kullanıma hazır, bağımsız bir pakette paketlerler. Görüntü içinde, dosya sistemi içeriği birden çok bağımsız katman olarak temsil edilir.

Katmanlar nedir?

Katmanlar, Docker görüntülerinin oluşturulma biçiminin bir sonucudur. Dockerfile’deki her adım, esasen son adımdan bu yana dosya sistemi değişikliklerinin bir farkı olan yeni bir “katman” oluşturur. Meta veri talimatları, örneğin LABEL ve MAINTAINER dosya sistemini etkilemedikleri için katmanlar oluşturmayın.

Bu görüntünün iki talimatı vardır (COPY ve RUN) böylece iki katman oluşturur:

FROM ubuntu:latest
COPY foo.txt /foo.txt
RUN date > /built-on.txt
  • İlk adım kopyalar foo.txt dayalı yeni bir katmana ubuntu:latest görüntü.
  • İkinci adım, date komut ve çıktısını bir dosyaya aktarır. Bu, öncekine dayanan ikinci bir katman oluşturur.

Oluşturmak foo.txt çalışma dizininizde:

$ echo "Hello World" > foo.txt

Şimdi örnek görüntüyü oluşturun:

$ docker build . -t demo:latest
Sending build context to Docker daemon   2.56kB
Step 1/3 : FROM ubuntu:latest
 ---> df5de72bdb3b
Step 2/3 : COPY foo.txt /foo.txt
 ---> 4932aede6a15
Step 3/3 : RUN date > /built-on.txt
 ---> Running in 91d260fc2e68
Removing intermediate container 91d260fc2e68
 ---> 6f653c6a60fa
Successfully built 6f653c6a60fa
Successfully tagged foo:latest

Her derleme adımı, oluşturulan katmanın kimliğini yayar. Son adımın katmanı son görüntü olur, böylece etiketlenir foo:latest.

Sıra bunu ortaya koyuyor katmanlar geçerli Docker görüntüleridir. “Katman” terimi normalde etiketli bir görüntüye atıfta bulunmak için kullanılmasa da, tüm etiketli görüntüler teknik olarak yalnızca bir tanımlayıcı atanmış katmanlardır.

Bir ara katmanın görüntüsünden bir kapsayıcı başlatabilirsiniz:

$ docker run -it 4932aede6a15 sh
# cat /foo.txt
Hello World
# cat /built-on.txt
cat: /built-on.txt: No such file or directory

Bu örnek, ikinci oluşturma adımı tarafından oluşturulan katmandan bir kapsayıcı başlatır. foo.txt kapta mevcut ama built-on.txt yok çünkü üçüncü adıma kadar eklenmedi. Bu dosya yalnızca sonraki katmanların dosya sistemlerinde bulunur.

Katmanların Rolü

Katmanlar, Dockerfile’deki önceki katmana göre bir derleme adımı tarafından oluşturulan değişiklikleri içerir. FROM talimatlar, mevcut bir görüntünün son katmanına başvuran özel bir durumdur.

Katmanlar, gereksiz çalışmayı önlemek için derleme adımlarının önbelleğe alınmasına izin verir. Docker, önceden oluşturulmuş katmanı yeniden kullanarak Dockerfile’nizdeki değişmeyen talimatları atlayabilir. Yeni bir tane oluşturmak yerine bir sonraki adımı mevcut katmana dayandırır.

Bunu, Dockerfile’ınızı aşağıdaki gibi değiştirerek görebilirsiniz:

FROM ubuntu:latest
COPY foo.txt /foo.txt
RUN date +%Y-%m-%d > /built-on.txt

Üçüncü inşa adımı değişti. Şimdi imajınızı yeniden oluşturun:

$ docker build . -t demo:latest
Sending build context to Docker daemon  3.584kB
Step 1/3 : FROM ubuntu:latest
 ---> df5de72bdb3b
Step 2/3 : COPY foo.txt /foo.txt
 ---> Using cache
 ---> 4932aede6a15
Step 3/3 : RUN date +%Y-%m-%d > /built-on.txt
 ---> Running in 2b91ec0462c4
Removing intermediate container 2b91ec0462c4
 ---> c6647ff378c1
Successfully built c6647ff378c1
Successfully tagged demo:latest

İkinci inşa adımı şu şekilde gösterilir: Using cache ve aynı katman kimliğini üretir. Docker, daha önce oluşturulduğu için bu katmanı oluşturmayı atlayabilir ve foo.txt ilk yapımdan beri değişmedi.

Bu önbelleğe alma, yalnızca bir katmanın değiştirildiği noktaya kadar çalışır. Bu katmandan sonraki tüm adımların da yeni dosya sistemi revizyonunu temel almaları için yeniden oluşturulması gerekecek.

Katmanlar ve Çekme İşlemleri

Katmanların bir başka yararı, kısmi görüntü çekmelerini nasıl etkinleştirdikleridir. Makinenize birkaç görüntü indirdikten sonra, genellikle yeni çekimlerin zaten sahip olduğunuz bazı katmanları atlayabileceğini göreceksiniz. Bu görüntü 13 katman içeriyor, ancak çekme işlemiyle yalnızca altı tanesinin indirilmesi gerekiyordu:

docker pull php:8.0-apache
8.0-apache: Pulling from library/php
7a6db449b51b: Already exists 
ad2afdb99a9d: Already exists 
dbc5aa907229: Already exists 
82f252ab4ad1: Already exists 
bf5b34fc9894: Already exists 
6161651d3d95: Already exists 
cf2adf296ef1: Already exists 
f0d7c5221e44: Pull complete 
f647198f6316: Pull complete 
c37afe1da4e5: Pull complete 
09c93531cbca: Pull complete 
fef371007dd3: Pull complete 
52043dbb1c06: Pull complete 
Digest: sha256:429889e8f9eac0a806a005b0728a004303b0d49d77b09496d39158707abd6280
Status: Downloaded newer image for php:8.0-apache
docker.io/library/php:8.0-apache

Diğer katmanlar, yeniden kullanılabilmeleri için Docker ana bilgisayarında zaten mevcuttu. Bu, performansı artırır ve ağ bant genişliğinin boşa harcanmasını önler.

Görüntü Katmanlarını İnceleme

çalıştırarak bir görüntüdeki katmanları listeleyebilirsiniz. docker image history emretmek. Her katman, oluşturulan görüntünün kimliğini ve değişikliğe neden olan Dockerfile komutunu görüntüler. Katman içindeki içeriğin toplam boyutunu da görebilirsiniz.

$ docker image history 
IMAGE          CREATED         CREATED BY                                      SIZE      COMMENT
6f653c6a60fa   4 minutes ago   /bin/sh -c date > /built-on.txt                 29B       
f8420d1a96f3   4 minutes ago   /bin/sh -c #(nop) COPY file:a5630a7506b26a37...   0B        
df5de72bdb3b   4 weeks ago     /bin/sh -c #(nop)  CMD ["bash"]                 0B        
<missing>      4 weeks ago     /bin/sh -c #(nop) ADD file:396eeb65c8d737180...   77.8MB    

Son katman olarak görüntülenir <missing> içindeki bir katmana atıfta bulunduğundan ubuntu:latest temel görüntü. Bu, yerel olarak kullanılamaz, çünkü yalnızca temel görüntünün son katmanı (df5de72bdb3b) oluşturma sırasında aşağı çekilir. Belirli bir görüntüyü kullanmak istediğinizde tüm ara katmanları bağımsız olarak çekmenize gerek yoktur.

Özet

Docker görüntüleri ve katmanları genellikle birbirinin yerine kullanılabilen terimlerdir. Katman bir görüntüdür ve bir veya daha fazla katmandan bir görüntü oluşturulur. En büyük fark etiketlerde yatmaktadır: bir görüntü etiketlenecek ve son kullanıcılar için tasarlanacaktır, “katman” terimi normalde bir oluşturma işleminin parçası olarak oluşturulan etiketlenmemiş ara görüntüleri ifade eder. Onları aramaya gitmedikçe bunlar görünmez.

Katmanlarla ilgili bir konu daha var: çalışan kapsayıcılar, görüntülerinin üzerine fazladan yazılabilir bir katman ekler. Kapsayıcının görüntüsünden kaynaklanan katmanlar salt okunurdur, bu nedenle kapsayıcı tarafından yapılan dosya sistemi değişiklikleri, geçici yazılabilir katmanını hedefler. Kapsayıcı durdurulduğunda veya silindiğinde yazılabilir katman atılır.

By admin

Leave a Reply

Your email address will not be published. Required fields are marked *

https://paddling.com/paddle/trips/latest-free-imvu-credits-generator-for-ios-android-no-apk-unlimited-imvu-credits-free https://paddling.com/paddle/trips/approved-how-to-get-free-diamonds-in-free-fire-ios-android-free-fire-diamond-generator-c98dsg https://paddling.com/paddle/trips/codesarchero-free-gems-generator-for-ios-android-redeem-codes-archero-2-cheats-unlimited-gems https://paddling.com/paddle/trips/999chapters-interactive-stories-free-diamonds-tickets-ios-android-chapters-hack-free-diamonds https://paddling.com/paddle/trips/999kfree-episode-gems-and-passes-ios-android-episode-gems-passes-generator-hack-998ds https://paddling.com/paddle/trips/latest-free-stumble-guys-gems-generator-for-ios-android-stumble-guys-hack-ios-no-apk-8dsg https://nothingbuttop10.bandcamp.com/album/paddling-gaming-9888 https://linktr.ee/cartecadeauxboxlivegratuit https://reach.link/carte-cadeau-xboxlive-gratuits https://kumu.io/codexboxlivegratuit/nouveaucarte-cadeau-xbox-live-gratuit-en-ligne https://kumu.io/codexboxlivegratuit/methode-code-xbox-live-gratuits-code-xbox-live-gold-gratuites-en-ligne https://nothingbuttop10.bandcamp.com/album/cartecadeau-xbox-live-gold-en-ligne https://www.dogomania.com/forum/topic/374282-%F0%9F%8E%B2-monopoly-go-hack-%E2%80%93-gratis-w%C3%BCrfel-ohne-anmeldung-sichern-ios-und-android/ https://www.dogomania.com/forum/topic/374283-neueste-so-bekommst-du-gratis-w%C3%BCrfel-monopoly-go-hack-auf-deutsch-ios-und-android-99999k/ https://www.dogomania.com/forum/topic/374284-degratis-w%C3%BCrfel-und-kostenlose-w%C3%BCrfel-links-august-2025-monopoly-go-hack-deutsch-heute-ios-android/ https://www.dogomania.com/forum/topic/374279-nuovo-come-avere-dadi-gratis-su-monopoly-go-hack-italian-dadi-gratis-infinite-per-ios-e-android-8c90sag/ https://www.dogomania.com/forum/topic/374280-100-dadi-monopoli-go-trucchi-come-ottenere-dadi-gratis-link-luglio-2025-per-ios-e-android-998dsfdsg/ https://www.dogomania.com/forum/topic/374281-trucchi-link-dadi-monopoly-go-gratis-hack-telegram-reddit-facebook-per-ios-e-android-~-9999k/ https://paddling.com/paddle/trips/latest-cod-mobile-free-cp-ios-android-how-to-get-free-cod-points-for-call-of-duty-mobile https://paddling.com/paddle/trips/latest-cod-mobile-free-cp-ios-android-how-to-get-free-cod-points-for-call-of-duty-mobile-2 https://aetherhub.com/Tourney/RoundTourney/66772 https://aetherhub.com/Tourney/RoundTourney/66775 https://aetherhub.com/Tourney/RoundTourney/66796 https://aetherhub.com/Tourney/RoundTourney/66797 https://aetherhub.com/Tourney/RoundTourney/66799 https://aetherhub.com/Tourney/RoundTourney/66802 https://aetherhub.com/Tourney/RoundTourney/66804 https://aetherhub.com/Tourney/RoundTourney/66805 https://aetherhub.com/Tourney/RoundTourney/66806 https://aetherhub.com/Tourney/RoundTourney/66807 https://aetherhub.com/Tourney/RoundTourney/66808 https://aetherhub.com/Tourney/RoundTourney/66809 https://aetherhub.com/Tourney/RoundTourney/66810 https://aetherhub.com/Tourney/RoundTourney/66811 https://nothingbuttop10.bandcamp.com/album/aetherde-2025 https://aetherhub.com/Tourney/RoundTourney/66828 https://aetherhub.com/Tourney/RoundTourney/66833 https://aetherhub.com/Tourney/RoundTourney/66834 https://aetherhub.com/Tourney/RoundTourney/66835 https://paddling.com/paddle/trips/updatedcod-mobile-free-cp-generator-ios-android-9999k-no-verification-9999k https://paddling.com/paddle/trips/redeemcall-of-duty-mobile-free-cp-ios-android-unlimited-cod-points-hack-2025-9999k https://paddling.com/paddle/trips/latest-free-cod-mobile-free-cp-android-apk-unlimited-cod-points-for-call-of-duty-mobile https://paddling.com/paddle/trips/crazy-call-of-duty-mobile-free-cod-points-cp-for-ios-android-updated-9999k https://nothingbuttop10.bandcamp.com/album/paddling-gaming-outbound-cod-links https://paddling.com/paddle/trips/newestepisode-unlimited-passes-and-gems-generator-for-ios-android-episode-choose-your-story-hacks https://paddling.com/paddle/trips/episode-free-gems-and-passes-ios-android-how-to-get-unlimited-gems-passes-for-episode-free https://paddling.com/paddle/trips/latest-episode-gems-and-passes-generator-ios-android-updated-9999k-unlimited https://paddling.com/paddle/trips/new-chapters-interactive-stories-free-diamonds-generator-ios-android-cheat-codes https://paddling.com/paddle/trips/999k-chapters-unlimited-diamonds-and-tickets-ios-android-free-999k https://paddling.com/paddle/trips/realchapters-mod-apk-unlimited-tickets-and-diamonds-for-android-ios-updated-link https://paddling.com/paddle/trips/match-masters-free-coins-hack-cheats-for-match-masters-ios-android-app-free-gift-links-today https://paddling.com/paddle/trips/latest-match-masters-free-coins-booster-links-match-masters-free-gifts-daily-generator-ios-android https://paddling.com/paddle/trips/booster-match-masters-free-coins-ios-android-updated-links-free-unlimited-coins-match-masters-gifts https://nothingbuttop10.bandcamp.com/album/holloplays-outbound-links https://paddling.com/paddle/trips/gratis-w%C3%BCrfel-monopoly-go-links-august-2025 https://paddling.com/paddle/trips/so-bekommst-du-gratis-w%C3%BCrfel-links-monopoly-go-hack-auf-deutsch-ios-android https://paddling.com/paddle/trips/so-bekommst-du-gratis-w%C3%BCrfel-dice-dreams-hack-auf-deutsch-ios-android https://paddling.com/paddle/trips/so-bekommst-du-gratis-diamanten-bei-chapters-hack-auf-deutsch-ios-android-9999 https://paddling.com/paddle/trips/so-bekommst-du-gratis-spins-und-m%C3%BCnzen-bei-coin-master-hack-auf-deutsch-link-2025 https://paddling.com/paddle/trips/so-bekommst-du-gratis-juwelen-in-brawl-stars-hack-auf-deutsch-ios-und-android-9999 https://paddling.com/paddle/trips/so-bekommst-du-gratis-credits-bei-bingo-blitz-hack-auf-deutsch-ios-und-android https://paddling.com/paddle/trips/so-bekommst-du-gratis-credits-bei-imvu-unendlich-credits-imvu-hack-auf-deutsch-ios-android https://paddling.com/paddle/trips/so-bekommst-du-gratis-juwelen-in-stumble-guys-hack-auf-deutsch-ios-android-999 https://paddling.com/paddle/trips/so-bekommst-du-gratis-goldbarren-bei-candy-crush-hack-auf-deutsch-ios-android-999 https://paddling.com/paddle/trips/so-bekommst-du-gratis-juwelen-in-clash-royale-hack-auf-deutsch-ios-und-android-999 https://paddling.com/paddle/trips/so-bekommst-du-gratis-juwelen-in-dragon-city-hack-auf-deutsch-ios-und-android-999 https://nothingbuttop10.bandcamp.com/album/paddling-de-spielen