Custom Debian Distributions Toolkit (CDDT)

Overview

Author: Sergio Talens-Oliag
Contact: sto@debian.org
Date: 2006-01-30 00:34:25 +0100 (dl, 30 gen 2006)

Introduction

There is a lot of people working on Custom Debian Distributions, but it seems that everyone is reinventing the wheel to do it.

This document describes the design of a Toolkit that tries to standardize the way developers define their CDD and provides tools to distribute, install, update and manage the customized systems.

The toolkit is being developed on the current CDD Project on alioth and discussed on the debian-custom@lists.debian.org mailing list.

Terminology

On this document we will use the following terms:

Toolkit Components

The system provides three sets of programs that are used for different purposes:

cddt-tools

This package contains tools to parse the source CDD description, generate CDD .deb and .udeb packages and build CDD installers.

The most important tool available on this package is the cddt program.

This program is written in Python and currently only supports the following subcommands:

  • tdeps: Print task dependencies
  • tfiles: Print files related to a task (and its dependencies)
  • tinfo: Print information about tasks
  • tmeta: Show metapackages' substvars

In the near future the cddt will be split into various programs:

  • cddt-dsc: used to parse the description file and generate debhelper compatible files (more or less done, as it will do what the current cddt supports),
  • cddt-pkg: used to generate metapackages using the cddt-dsc output (now that is done by hand),
  • cddt-cdd: used to build a debian-installer using the metapackages (now that is done by hand),
  • cddt: frontend to the other programs used to maintain the CDD installation; that program will probably be moved to the support programs section and will be written in shell.

cddt-runtime

This package contains support programs used to select, install, configure, upgrade and remove CDD tasks included on the CDD binary description packages currently installed on a system.

The scripts are written in shell to avoid additional dependencies (the CDD can be installed without requiring a Python interpreter).

The package includes a shell library with functions to build the frontend of configuration scripts (the same code can be used for X, console and text terminals), functions to read variables stored on files and replace the value of those variables on template files or functions to install customized versions of files while keeping copies of the original versions (this functionality is available to end users and developers through the cddt-divert program).

The package also contains hooks for apt and ifupdown that can be used to apply and remove customizations at package installation time (the apt hooks) and when the network interfaces are bought up or down. Those hooks call a set of scripts that can be installed directly on their place or put on separate directories and enabled and disabled by the system administrator.

cddt-installer

Currently unnimplemented, the idea is to have an standard udeb that once included on the debian-installer allows the user to install a CDD directly; this tool will use as input the data included on a CDD udeb generated from the information included on the CDD description file.