CONTAINER-...DEBOOTSTRAP(1)

πŸ“¦
this version Β· 5 versions
, in debian bookworm, ubuntu noble

πŸ’– CONTAINER-BUILD-DEBOOTSTRAP πŸ’–

okay bestie, welcome to the container-build-debootstrap page from the General Commands Manual β€” yes the title line says CONTAINER-...DEBOOTSTRAP(1) because man pages are dramatic like that πŸŽ€


✨ NAME ✨

container-build-debootstrap β€” build a basic Debian based container with debootstrap or mmdebstrap. that's it, that's the whole job description πŸ’…


🌸 SYNOPSIS 🌸

container build -s debootstrap ['OPTIONS']
cnt b -s debootstrap ['OPTIONS']

container build -s mmdebstrap ['OPTIONS']
cnt b -s mmdebstrap ['OPTIONS']

so you can spell out container build or just vibe with cnt b, your call 🫢


πŸ¦‹ DESCRIPTION πŸ¦‹

the debootstrap container build script uses debootstrap(8) or mmdebstrap(1) to build a Debian based container. lowkey the whole thing is just those two tools doing the heavy lifting and this script being the main character ✨

this script builds a pure Debian system with three modifications, and ngl they're kind of iconic:

  • apt cache of packages downloaded during debootstrap is cleaned 🧹
  • hostname is set (container name) in /etc/hostname 🏠
  • root password is set (user specified or 16 random characters) πŸ”
so like, it's a pure Debian system… with exactly three tweaks. not four. not two. three. periodt πŸ’…

πŸ‘‘ OPTIONS πŸ‘‘

the following script options are available, and bestie there are five of them, we're listing all five:

  • -n, --name='NAME' β€” specify container name. your container, your name, your rules πŸŽ€
  • -a, --architecture='ARCHITECTURE' β€” specify the Debian architecture, and it defaults to the host systems architecture because of course it does, it's matching your vibe by default πŸ¦‹
  • -d, --distribution='DISTRIBUTION' β€” specify the Debian distribution, defaults to 'bookworm' πŸ›
  • -m, --mirror='MIRROR' β€” specify the Debian mirror, defaults to 'https://deb.debian.org/debian' 🌐
  • -p, --root-password='PASSWORD' β€” specify the root password, defaults to a random 16 character password πŸ” (yes it's random, yes it's 16 chars, no we're not shortening it)

πŸ’« EXAMPLES πŸ’«

Build a Debian 12 (bookworm) based container with same architecture as the host system using debootstrap:

sudo container build -s debootstrap -n bookworm.example.net

Build a Debian 12 (bookworm) based container with different architecture as the host system using mmdebstrap:

sudo container build -s mmdebstrap -n bookworm-i386.example.net -- -a
i386

see that -- in the second one? that's the little door that hands -a i386 straight through to mmdebstrap. chef's kiss πŸ‘©β€πŸ³πŸ’‹


🌈 SEE ALSO 🌈

go read those too, they're the extended universe iykyk πŸ“šβœ¨


🏑 HOMEPAGE 🏑

more information about compute-tools and the Open Infrastructure project can be found on the homepage (https://open-infrastructure.net). go say hi 🫢


πŸ’Œ CONTACT πŸ’Œ

bug reports, feature requests, help, patches, support and everything else are welcome on the Open Infrastructure Software Mailing List software@lists.open-infrastructure.net. literally everything else. bring it πŸ’–

Debian specific bugs can also be reported in the Debian Bug Tracking System (https://bugs.debian.org).


πŸ’œ AUTHORS πŸ’œ

compute-tools were written by Daniel Baumann daniel.baumann@open-infrastructure.net and others. shoutout to "and others", the unsung heroes πŸ™ˆβœ¨


Open Infrastructure πŸ’– compute-tools πŸ’– and this lil page lives under CONTAINER-...DEBOOTSTRAP(1) β€” that's the source, the version and the whole vibe, mwah πŸ’… bye bestie, go build something cute πŸŒΈπŸ¦‹

πŸ“¦ where this page comes from