SlideShare a Scribd company logo
Copyright©2019 NTT Corp. All Rights Reserved.
Akihiro Suda ( @_AkihiroSuda_ )
NTT Software Innovation Center
My ISC HPCW Talks
1. Current state of rootless dockerd
2. Rootless build with BuildKit
3. OCI Image Spec & Distribution
5th Annual High Performance Container Workshop, ISC (June 20, 2019)
Copyright©2019 NTT Corp. All Rights Reserved.
Akihiro Suda ( @_AkihiroSuda_ )
NTT Software Innovation Center
Current state of rootless dockerd
5th Annual High Performance Container Workshop, ISC (June 20, 2019)
3

Copyright©2019 NTT Corp. All Rights Reserved.
What is rootless dockerd?
• Run Docker daemon (and also containers of course) as a
non-root user
• Don’t confuse with:
• sudo
• usermod -aG docker penguin
• docker run --user
• dockerd --userns-remap
• Experimentally supported since Docker v19.03
https://get.docker.com/rootless
Image: https://xkcd.com/149/
4

Copyright©2019 NTT Corp. All Rights Reserved.
Why?
• For Cloud-Native envs:
• To mitigate potential vulnerability of container runtimes and
orchestrator
• For HPC envs:
• To run containers without the risk of breaking other users
environments
5

Copyright©2019 NTT Corp. All Rights Reserved.
How it works: User Namespaces
• User namespaces allow non-root users to pretend to be
the root
• Root-in-UserNS can have “fake” UID 0 and also create
other namespaces (MountNS, NetNS..)
• Unlike Singularity, NetNS can be unshared
• By using either usermode TCP/IP stack (VPNKit, slirp4netns) or
SETUID binary (lxc-user-nic)
6

Copyright©2019 NTT Corp. All Rights Reserved.
System requirements: /etc/{subuid,subgid}
• If /etc/subuid contains “1001:100000:65536”
• Having 65536 sub-users should be enough for most
containers
0 1001 100000 165535 232Host
UserNS
primary user
sub-users
start
sub-users
length
0 1 65536
7

Copyright©2019 NTT Corp. All Rights Reserved.
Unresolved issues (Contribution wanted!)
• Hard to maintain subuid & subgid in LDAP/AD envs
• NSS module is being under discussion
https://github.com/shadow-maint/shadow/issues/154
• Single-mapping mode w/o subuid & subgid is also under
discussion
• uses ptrace and xattrs
(slow!)
• seccomp could be
used for acceleration
https://github.com/rootless-containers/runrootless
8

Copyright©2019 NTT Corp. All Rights Reserved.
Unresolved issues (Contribution wanted!)
• Lacks cgroup
• cgroup2 (unified-mode) supports unprivileged mode but
migration may take a few years… or even more
• For cgroup1, pam_cgfs could be used instead, but not available
in Fedora / RHEL due to a security concern
• Kernel / VM / HW may have vulns
• Not suitable for real multi-tenancy
• gVisor might able to mitigate some of them
Copyright©2019 NTT Corp. All Rights Reserved.
Akihiro Suda ( @_AkihiroSuda_ )
NTT Software Innovation Center
Rootless build with BuildKit
5th Annual High Performance Container Workshop, ISC (June 20, 2019)
10

Copyright©2019 NTT Corp. All Rights Reserved.
What is BuildKit?
• Next-generation docker build with focus on performance
and security
• Accurate dependency analysis
• Concurrent execution of independent instructions
• Support injecting secret files...
• Integrated to Docker since v18.06
(export DOCKER_BUILDKIT=1)
• Non-Docker standalone BuildKit is also available
• Works with Podman and CRI-O as well :P
11

Copyright©2019 NTT Corp. All Rights Reserved.
Rootless mode
• Rootless mode allows building images as a non-root user
• Dockerfile RUN instructions are executed as a “fake root” in
UserNS (So apt-get/yum works!)
• Produces Docker image / OCI image / raw tarball
• Compatible with Rootless Docker / Rootless Podman / …
whatever
• Even works inside a container
• Good for distributed CI/CD on Kubernetes
• Works with default securityContext configuration
(but seccomp and AppArmor needs to be disabled for nesting containers)
12

Copyright©2019 NTT Corp. All Rights Reserved.
Rootless BuildKit vs kaniko
• https://github.com/GoogleContainerTools/kaniko
• Kaniko runs as the root but “unprivileged”
• No need to disable seccomp and AppArmor because kaniko
doesn’t nest containers on the kaniko container itself
• Kaniko might be able to mitigate some vuln that Rootless
BuildKit cannot mitigate - and vice versa
• Rootless BuildKit might be weak against kernel vulns
• Kaniko might be weak against runc vulns
Copyright©2019 NTT Corp. All Rights Reserved.
Akihiro Suda ( @_AkihiroSuda_ )
NTT Software Innovation Center
OCI Image Spec & Distribution
5th Annual High Performance Container Workshop, ISC (June 20, 2019)
14

Copyright©2019 NTT Corp. All Rights Reserved.
Open Containers Initiative Specifications
• OCI Runtime Spec
• How to create container from config JSON and rootfs dir
• Based on Docker libcontainer (now runc)
• OCI Image Spec
• How to represent image layers for OCI runtimes
• Based on Docker Image Manifest V2, Schema 2
• OCI Distribution Spec
• How to distribute OCI images
• Based on Docker Registry HTTP API
15

Copyright©2019 NTT Corp. All Rights Reserved.
Image layout
/blobs/sha256/e692418e...
/blobs/sha256/b5b2b2c5...
/blobs/sha256/61be55a8...
/blobs/sha256/3c3a4604...
/blobs/sha256/3c3a4604...
JSON
JSON
tar.gz
tar.gz
tar.gz
Manifest
• Merkle DAG structure ensures reproducibility of
docker pull foo@sha256:e692418e…
Container Config
AUFS layer archives
(for each Dockerfile
FROM and RUN)
v1.0Manifest list latest
16

Copyright©2019 NTT Corp. All Rights Reserved.
Image layout
latest
amd64
/blobs/sha256/e692418e...
/blobs/sha256/b5b2b2c5...
/blobs/sha256/61be55a8...
/blobs/sha256/3c3a4604...
/blobs/sha256/3c3a4604...
JSON
JSON
tar.gz
tar.gz
tar.gz
JSON
Manifest list
Manifest
• Supports multi-arch (use BuildKit to build)
Container Config
latest
arm64
AUFS layer archives
(for each Dockerfile
FROM and RUN)
17

Copyright©2019 NTT Corp. All Rights Reserved.
Image layout
latest
Ice Lake
/blobs/sha256/e692418e...
/blobs/sha256/b5b2b2c5...
/blobs/sha256/61be55a8...
/blobs/sha256/3c3a4604...
/blobs/sha256/3c3a4604...
JSON
JSON
tar.gz
tar.gz
tar.gz
JSON
Manifest list
Manifest
• And even multi-microarchitectures via qnib/metahub
• https://metahub.qnib.org
Container Config
latest
Broadwell
Tesla M60
AUFS layer archives
(for each Dockerfile
FROM and RUN)
18

Copyright©2019 NTT Corp. All Rights Reserved.
Post-OCI image format?
• Issues of current OCI v1
• Too coarse deduplication granularity
• Containers cannot be started until the entire image is pulled
• An alternative: CernVM-FS
• Supports file-level deduplication rather than layer-level
• Files are lazy-pulled on demand using FUSE
• Integrating CernVM-FS to containerd is under discussion
https://github.com/containerd/containerd/issues/2943
19

Copyright©2019 NTT Corp. All Rights Reserved.
Post-OCI image format?
• ”OCI v2” https://github.com/openSUSE/umoci/issues/256
• Much finer deduplication granularity
• No implementation yet
• Container Registry Filesystem https://github.com/google/crfs
• Focus on lazy-pulling CI images
• IPCS https://github.com/hinshun/ipcs
• IPFS integration for containerd

More Related Content

PDF
Comparing Next-Generation Container Image Building Tools
PDF
[Paris Container Day 2021] nerdctl: yet another Docker & Docker Compose imple...
PDF
[KubeCon NA 2020] containerd: Rootless Containers 2020
PDF
[DockerCon 2020] Hardening Docker daemon with Rootless Mode
PDF
[KubeCon EU 2020] containerd Deep Dive
PDF
[KubeConEU] Building images efficiently and securely on Kubernetes with BuildKit
PDF
[KubeConUS2019 Docker, Inc. Booth] Distributed Builds on Kubernetes with Bui...
PDF
Rootless Containers
Comparing Next-Generation Container Image Building Tools
[Paris Container Day 2021] nerdctl: yet another Docker & Docker Compose imple...
[KubeCon NA 2020] containerd: Rootless Containers 2020
[DockerCon 2020] Hardening Docker daemon with Rootless Mode
[KubeCon EU 2020] containerd Deep Dive
[KubeConEU] Building images efficiently and securely on Kubernetes with BuildKit
[KubeConUS2019 Docker, Inc. Booth] Distributed Builds on Kubernetes with Bui...
Rootless Containers

What's hot (20)

PDF
Rootless Containers & Unresolved issues
PDF
Rootless Kubernetes
PPTX
Usernetes: Kubernetes as a non-root user
PDF
[KubeCon EU 2021] Introduction and Deep Dive Into Containerd
PDF
The State of Rootless Containers
PDF
[DockerCon 2019] Hardening Docker daemon with Rootless mode
PDF
[FOSDEM 2020] Lazy distribution of container images
PDF
Upstate DevOps - Containers 101 - March 28, 2019
ODP
Docker engine - Indroduc
PDF
SCALE 2011 Deploying OpenStack with Chef
PDF
Introduction and Deep Dive Into Containerd
PPTX
Java applications containerized and deployed
PPTX
A deep dive into container technology - Vietnam Web Summit 2020 (18/12/2020)
PDF
Faster Container Image Distribution on a Variety of Tools with Lazy Pulling
PDF
containerdの概要と最近の機能
PPTX
Secure container: Kata container and gVisor
PPTX
Docker open stack boston
PDF
Docker and OpenStack Boston Meetup
PDF
P2P Container Image Distribution on IPFS With containerd and nerdctl
PDF
App container rkt
Rootless Containers & Unresolved issues
Rootless Kubernetes
Usernetes: Kubernetes as a non-root user
[KubeCon EU 2021] Introduction and Deep Dive Into Containerd
The State of Rootless Containers
[DockerCon 2019] Hardening Docker daemon with Rootless mode
[FOSDEM 2020] Lazy distribution of container images
Upstate DevOps - Containers 101 - March 28, 2019
Docker engine - Indroduc
SCALE 2011 Deploying OpenStack with Chef
Introduction and Deep Dive Into Containerd
Java applications containerized and deployed
A deep dive into container technology - Vietnam Web Summit 2020 (18/12/2020)
Faster Container Image Distribution on a Variety of Tools with Lazy Pulling
containerdの概要と最近の機能
Secure container: Kata container and gVisor
Docker open stack boston
Docker and OpenStack Boston Meetup
P2P Container Image Distribution on IPFS With containerd and nerdctl
App container rkt
Ad

Similar to ISC HPCW talks (20)

PDF
DCSF19 Hardening Docker daemon with Rootless mode
PDF
Build and run applications in a dockerless kubernetes world
PDF
Linux Containers and Docker SHARE.ORG Seattle 2015
PDF
Using Docker with OpenStack - Hands On!
PDF
Container Runtimes: Comparing and Contrasting Today's Engines
PDF
Containers without docker | DevNation Tech Talk
PDF
Building Containers: How Many Ways Are Too Many?
PDF
Docker 0.11 at MaxCDN meetup in Los Angeles
PDF
Build and run applications in a dockerless kubernetes world - DevConf India 18
PDF
Docker and-containers-for-development-and-deployment-scale12x
PPTX
Central Iowa Linux Users Group: November Meeting -- Container showdown
PDF
Docker_AGH_v0.1.3
PDF
Navigating container technology for enhanced security by Niklas Saari
PDF
Docker Introduction + what is new in 0.9
PDF
Docker Introduction, and what's new in 0.9 — Docker Palo Alto at RelateIQ
PDF
Docker from scratch
PDF
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies
PDF
Introduction to Containers - From Docker to Kubernetes and everything in between
PPTX
SummerStudent17_HandsOn Data Cloud Computing.pptx
PDF
Introduction to Docker at SF Peninsula Software Development Meetup @Guidewire
DCSF19 Hardening Docker daemon with Rootless mode
Build and run applications in a dockerless kubernetes world
Linux Containers and Docker SHARE.ORG Seattle 2015
Using Docker with OpenStack - Hands On!
Container Runtimes: Comparing and Contrasting Today's Engines
Containers without docker | DevNation Tech Talk
Building Containers: How Many Ways Are Too Many?
Docker 0.11 at MaxCDN meetup in Los Angeles
Build and run applications in a dockerless kubernetes world - DevConf India 18
Docker and-containers-for-development-and-deployment-scale12x
Central Iowa Linux Users Group: November Meeting -- Container showdown
Docker_AGH_v0.1.3
Navigating container technology for enhanced security by Niklas Saari
Docker Introduction + what is new in 0.9
Docker Introduction, and what's new in 0.9 — Docker Palo Alto at RelateIQ
Docker from scratch
Podman, Buildah, and Quarkus - The Latest in Linux Containers Technologies
Introduction to Containers - From Docker to Kubernetes and everything in between
SummerStudent17_HandsOn Data Cloud Computing.pptx
Introduction to Docker at SF Peninsula Software Development Meetup @Guidewire
Ad

More from Akihiro Suda (20)

PDF
20250617 [KubeCon JP 2025] containerd - Project Update and Deep Dive.pdf
PDF
20250616 [KubeCon JP 2025] VexLLM - Silence Negligible CVE Alerts Using LLM.pdf
PDF
20250403 [KubeCon EU] containerd - Project Update and Deep Dive.pdf
PDF
20250403 [KubeCon EU Pavilion] containerd.pdf
PDF
20250402 [KubeCon EU Pavilion] Lima.pdf_
PDF
20241115 [KubeCon NA Pavilion] Lima.pdf_
PDF
20241113 [KubeCon NA Pavilion] containerd.pdf
PDF
【情報科学若手の会 (2024/09/14】なぜオープンソースソフトウェアにコントリビュートすべきなのか
PDF
【Vuls祭り#10 (2024/08/20)】 VexLLM: LLMを用いたVEX自動生成ツール
PDF
20240415 [Container Plumbing Days] Usernetes Gen2 - Kubernetes in Rootless Do...
PDF
20240321 [KubeCon EU Pavilion] Lima.pdf_
PDF
20240320 [KubeCon EU Pavilion] containerd.pdf
PDF
20240201 [HPC Containers] Rootless Containers.pdf
PDF
[Podman Special Event] Kubernetes in Rootless Podman
PDF
[KubeConNA2023] Lima pavilion
PDF
[KubeConNA2023] containerd pavilion
PDF
[DockerConハイライト] OpenPubKeyによるイメージの署名と検証.pdf
PDF
[CNCF TAG-Runtime] Usernetes Gen2
PDF
[DockerCon 2023] Reproducible builds with BuildKit for software supply chain ...
PDF
The internals and the latest trends of container runtimes
20250617 [KubeCon JP 2025] containerd - Project Update and Deep Dive.pdf
20250616 [KubeCon JP 2025] VexLLM - Silence Negligible CVE Alerts Using LLM.pdf
20250403 [KubeCon EU] containerd - Project Update and Deep Dive.pdf
20250403 [KubeCon EU Pavilion] containerd.pdf
20250402 [KubeCon EU Pavilion] Lima.pdf_
20241115 [KubeCon NA Pavilion] Lima.pdf_
20241113 [KubeCon NA Pavilion] containerd.pdf
【情報科学若手の会 (2024/09/14】なぜオープンソースソフトウェアにコントリビュートすべきなのか
【Vuls祭り#10 (2024/08/20)】 VexLLM: LLMを用いたVEX自動生成ツール
20240415 [Container Plumbing Days] Usernetes Gen2 - Kubernetes in Rootless Do...
20240321 [KubeCon EU Pavilion] Lima.pdf_
20240320 [KubeCon EU Pavilion] containerd.pdf
20240201 [HPC Containers] Rootless Containers.pdf
[Podman Special Event] Kubernetes in Rootless Podman
[KubeConNA2023] Lima pavilion
[KubeConNA2023] containerd pavilion
[DockerConハイライト] OpenPubKeyによるイメージの署名と検証.pdf
[CNCF TAG-Runtime] Usernetes Gen2
[DockerCon 2023] Reproducible builds with BuildKit for software supply chain ...
The internals and the latest trends of container runtimes

Recently uploaded (20)

PDF
medical staffing services at VALiNTRY
PDF
How Creative Agencies Leverage Project Management Software.pdf
PDF
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
PDF
How to Choose the Right IT Partner for Your Business in Malaysia
PDF
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 41
PDF
Design an Analysis of Algorithms I-SECS-1021-03
PDF
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
PDF
AI in Product Development-omnex systems
PPTX
Online Work Permit System for Fast Permit Processing
PDF
Digital Strategies for Manufacturing Companies
PDF
Nekopoi APK 2025 free lastest update
PPTX
CHAPTER 12 - CYBER SECURITY AND FUTURE SKILLS (1) (1).pptx
PPTX
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
PPTX
Operating system designcfffgfgggggggvggggggggg
PDF
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PDF
PTS Company Brochure 2025 (1).pdf.......
PDF
Navsoft: AI-Powered Business Solutions & Custom Software Development
PDF
Understanding Forklifts - TECH EHS Solution
PDF
2025 Textile ERP Trends: SAP, Odoo & Oracle
medical staffing services at VALiNTRY
How Creative Agencies Leverage Project Management Software.pdf
Why TechBuilder is the Future of Pickup and Delivery App Development (1).pdf
How to Choose the Right IT Partner for Your Business in Malaysia
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
Internet Downloader Manager (IDM) Crack 6.42 Build 41
Design an Analysis of Algorithms I-SECS-1021-03
Internet Downloader Manager (IDM) Crack 6.42 Build 42 Updates Latest 2025
AI in Product Development-omnex systems
Online Work Permit System for Fast Permit Processing
Digital Strategies for Manufacturing Companies
Nekopoi APK 2025 free lastest update
CHAPTER 12 - CYBER SECURITY AND FUTURE SKILLS (1) (1).pptx
Agentic AI Use Case- Contract Lifecycle Management (CLM).pptx
Operating system designcfffgfgggggggvggggggggg
Addressing The Cult of Project Management Tools-Why Disconnected Work is Hold...
PTS Company Brochure 2025 (1).pdf.......
Navsoft: AI-Powered Business Solutions & Custom Software Development
Understanding Forklifts - TECH EHS Solution
2025 Textile ERP Trends: SAP, Odoo & Oracle

ISC HPCW talks

  • 1. Copyright©2019 NTT Corp. All Rights Reserved. Akihiro Suda ( @_AkihiroSuda_ ) NTT Software Innovation Center My ISC HPCW Talks 1. Current state of rootless dockerd 2. Rootless build with BuildKit 3. OCI Image Spec & Distribution 5th Annual High Performance Container Workshop, ISC (June 20, 2019)
  • 2. Copyright©2019 NTT Corp. All Rights Reserved. Akihiro Suda ( @_AkihiroSuda_ ) NTT Software Innovation Center Current state of rootless dockerd 5th Annual High Performance Container Workshop, ISC (June 20, 2019)
  • 3. 3
 Copyright©2019 NTT Corp. All Rights Reserved. What is rootless dockerd? • Run Docker daemon (and also containers of course) as a non-root user • Don’t confuse with: • sudo • usermod -aG docker penguin • docker run --user • dockerd --userns-remap • Experimentally supported since Docker v19.03 https://get.docker.com/rootless Image: https://xkcd.com/149/
  • 4. 4
 Copyright©2019 NTT Corp. All Rights Reserved. Why? • For Cloud-Native envs: • To mitigate potential vulnerability of container runtimes and orchestrator • For HPC envs: • To run containers without the risk of breaking other users environments
  • 5. 5
 Copyright©2019 NTT Corp. All Rights Reserved. How it works: User Namespaces • User namespaces allow non-root users to pretend to be the root • Root-in-UserNS can have “fake” UID 0 and also create other namespaces (MountNS, NetNS..) • Unlike Singularity, NetNS can be unshared • By using either usermode TCP/IP stack (VPNKit, slirp4netns) or SETUID binary (lxc-user-nic)
  • 6. 6
 Copyright©2019 NTT Corp. All Rights Reserved. System requirements: /etc/{subuid,subgid} • If /etc/subuid contains “1001:100000:65536” • Having 65536 sub-users should be enough for most containers 0 1001 100000 165535 232Host UserNS primary user sub-users start sub-users length 0 1 65536
  • 7. 7
 Copyright©2019 NTT Corp. All Rights Reserved. Unresolved issues (Contribution wanted!) • Hard to maintain subuid & subgid in LDAP/AD envs • NSS module is being under discussion https://github.com/shadow-maint/shadow/issues/154 • Single-mapping mode w/o subuid & subgid is also under discussion • uses ptrace and xattrs (slow!) • seccomp could be used for acceleration https://github.com/rootless-containers/runrootless
  • 8. 8
 Copyright©2019 NTT Corp. All Rights Reserved. Unresolved issues (Contribution wanted!) • Lacks cgroup • cgroup2 (unified-mode) supports unprivileged mode but migration may take a few years… or even more • For cgroup1, pam_cgfs could be used instead, but not available in Fedora / RHEL due to a security concern • Kernel / VM / HW may have vulns • Not suitable for real multi-tenancy • gVisor might able to mitigate some of them
  • 9. Copyright©2019 NTT Corp. All Rights Reserved. Akihiro Suda ( @_AkihiroSuda_ ) NTT Software Innovation Center Rootless build with BuildKit 5th Annual High Performance Container Workshop, ISC (June 20, 2019)
  • 10. 10
 Copyright©2019 NTT Corp. All Rights Reserved. What is BuildKit? • Next-generation docker build with focus on performance and security • Accurate dependency analysis • Concurrent execution of independent instructions • Support injecting secret files... • Integrated to Docker since v18.06 (export DOCKER_BUILDKIT=1) • Non-Docker standalone BuildKit is also available • Works with Podman and CRI-O as well :P
  • 11. 11
 Copyright©2019 NTT Corp. All Rights Reserved. Rootless mode • Rootless mode allows building images as a non-root user • Dockerfile RUN instructions are executed as a “fake root” in UserNS (So apt-get/yum works!) • Produces Docker image / OCI image / raw tarball • Compatible with Rootless Docker / Rootless Podman / … whatever • Even works inside a container • Good for distributed CI/CD on Kubernetes • Works with default securityContext configuration (but seccomp and AppArmor needs to be disabled for nesting containers)
  • 12. 12
 Copyright©2019 NTT Corp. All Rights Reserved. Rootless BuildKit vs kaniko • https://github.com/GoogleContainerTools/kaniko • Kaniko runs as the root but “unprivileged” • No need to disable seccomp and AppArmor because kaniko doesn’t nest containers on the kaniko container itself • Kaniko might be able to mitigate some vuln that Rootless BuildKit cannot mitigate - and vice versa • Rootless BuildKit might be weak against kernel vulns • Kaniko might be weak against runc vulns
  • 13. Copyright©2019 NTT Corp. All Rights Reserved. Akihiro Suda ( @_AkihiroSuda_ ) NTT Software Innovation Center OCI Image Spec & Distribution 5th Annual High Performance Container Workshop, ISC (June 20, 2019)
  • 14. 14
 Copyright©2019 NTT Corp. All Rights Reserved. Open Containers Initiative Specifications • OCI Runtime Spec • How to create container from config JSON and rootfs dir • Based on Docker libcontainer (now runc) • OCI Image Spec • How to represent image layers for OCI runtimes • Based on Docker Image Manifest V2, Schema 2 • OCI Distribution Spec • How to distribute OCI images • Based on Docker Registry HTTP API
  • 15. 15
 Copyright©2019 NTT Corp. All Rights Reserved. Image layout /blobs/sha256/e692418e... /blobs/sha256/b5b2b2c5... /blobs/sha256/61be55a8... /blobs/sha256/3c3a4604... /blobs/sha256/3c3a4604... JSON JSON tar.gz tar.gz tar.gz Manifest • Merkle DAG structure ensures reproducibility of docker pull foo@sha256:e692418e… Container Config AUFS layer archives (for each Dockerfile FROM and RUN) v1.0Manifest list latest
  • 16. 16
 Copyright©2019 NTT Corp. All Rights Reserved. Image layout latest amd64 /blobs/sha256/e692418e... /blobs/sha256/b5b2b2c5... /blobs/sha256/61be55a8... /blobs/sha256/3c3a4604... /blobs/sha256/3c3a4604... JSON JSON tar.gz tar.gz tar.gz JSON Manifest list Manifest • Supports multi-arch (use BuildKit to build) Container Config latest arm64 AUFS layer archives (for each Dockerfile FROM and RUN)
  • 17. 17
 Copyright©2019 NTT Corp. All Rights Reserved. Image layout latest Ice Lake /blobs/sha256/e692418e... /blobs/sha256/b5b2b2c5... /blobs/sha256/61be55a8... /blobs/sha256/3c3a4604... /blobs/sha256/3c3a4604... JSON JSON tar.gz tar.gz tar.gz JSON Manifest list Manifest • And even multi-microarchitectures via qnib/metahub • https://metahub.qnib.org Container Config latest Broadwell Tesla M60 AUFS layer archives (for each Dockerfile FROM and RUN)
  • 18. 18
 Copyright©2019 NTT Corp. All Rights Reserved. Post-OCI image format? • Issues of current OCI v1 • Too coarse deduplication granularity • Containers cannot be started until the entire image is pulled • An alternative: CernVM-FS • Supports file-level deduplication rather than layer-level • Files are lazy-pulled on demand using FUSE • Integrating CernVM-FS to containerd is under discussion https://github.com/containerd/containerd/issues/2943
  • 19. 19
 Copyright©2019 NTT Corp. All Rights Reserved. Post-OCI image format? • ”OCI v2” https://github.com/openSUSE/umoci/issues/256 • Much finer deduplication granularity • No implementation yet • Container Registry Filesystem https://github.com/google/crfs • Focus on lazy-pulling CI images • IPCS https://github.com/hinshun/ipcs • IPFS integration for containerd