FixMe: live-package is obsolete and is superceded by live-helper. If you want to keep this page, please revise the following to refer to live-helper. You will find updated info on the DebianLive site concerning live-helper configuration. Many aspects of the build process have changed, and are well documented on the main site.

Creating a Custom LiveCD with Fluxbox using live-package

Steps:

  1. Install live-package
  2. configure /etc/make-live.conf
  3. first make-live run: create basic chroot
  4. install gdm/fluxbox within chroot
  5. set defaults for user casper
  6. re-create squashfs and iso image
  7. test it using qemu

if everything goes well you will end up booting an livecd with fluxbox as window manager and auto-logon. The iso image will be about 126 MB (with /usr/share/doc and other things removed).


1. Install live-package

$ sudo apt-get install live-package


2. configure /etc/make-live.conf

thats what my /etc/make-live.conf looks like:

Note: it wont support networking, if you want so, use minimal-net as LIVE_FLAVOUR

LIVE_ARCHITECTURE="i386"
LIVE_CONFIG="/etc/make-live.conf"
LIVE_DISTRIBUTION="testing"
LIVE_FLAVOUR="minimal"
LIVE_MIRROR="http://my.local.mirror/debian"
LIVE_MIRROR_SECURITY="http://my.local.mirror/debian-security"
LIVE_PACKAGE_LIST="x11"


3. first make-live run: create basic chroot

# make-live

after make-live finished creating a minimal chroot you will end up with the following stuff in your directory:

debian-live/
drwxr-xr-x  2 root root 4.0K Nov 17 14:22 .stage
drwxr-xr-x  4 root root 4.0K Nov 17 14:22 binary
-rw-r--r--  1 root root 127M Nov 17 15:23 binary.iso
drwxr-xr-x 20 root root 4.0K Nov 17 14:22 chroot


4. install gdm/fluxbox within chroot

switch to your chroot, remove xdm (doesnt support auto-login afaik), install gdm and fluxbox:

# chroot debian-live/chroot
# apt-get remove --purge xdm
# apt-get install gdm fluxbox
# exit

repeat this for other software you like to see in your live cd.


5. set defaults for user casper

the live-cd's default user is casper, /home/casper will be crated during boot from /etc/skel, so everything we want to pre-configure (like keyboard layout and default window manager) should be placed there:

tell gdm about fluxbox, use it for auto-logon:

echo "Session=fluxbox" >debian-live/chroot/etc/skel/.dmrc

set keyboard layout for Xserver (example for german layout, dont forget to create your locales within the chroot)

echo "de" >debian-live/chroot/etc/skel/.Xkbmap

[..]


6. re-create squashfs and iso image

LIVE_ROOT=debian-live
LIVE_CHROOT=debian-live/chroot

rm -f ${LIVE_ROOT}/binary/casper/filesystem.*
rm -f ${LIVE_ROOT}/*.iso

mksquashfs "${LIVE_CHROOT}" "${LIVE_ROOT}"/binary/casper/filesystem.squashfs

mkisofs -A "Debian Live" -p "Custom Debian Live CDROM;" \                                                                                                              -publisher "The Live CD Cabal" \                                                                                                                               -o "${LIVE_ROOT}"/"${LIVE_IMAGE}"binary.iso \                                                                                                                  -r -J -l -V "Debian Live `date +%Y%m%d`" \                                                                                                                     -b isolinux/isolinux.bin -c isolinux/boot.cat -no-emul-boot \ 
         -boot-load-size 4 -boot-info-table "${LIVE_ROOT}"/binary 


7. test it using qemu

qemu -m <amount of memory for qemu> -cdrom debian-live/binary.iso