Skip to content

Instantly share code, notes, and snippets.

@detly
Created January 12, 2016 06:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save detly/54e07c56f68b9d2ed066 to your computer and use it in GitHub Desktop.
Save detly/54e07c56f68b9d2ed066 to your computer and use it in GitHub Desktop.
live-build config
#!/bin/sh
set -e
if [ -z "${HAN_APT_CACHE}" ] ; then
MIR_PREFIX="http://"
else
MIR_PREFIX="${HAN_APT_CACHE}/"
fi
MIR_REP="${MIR_PREFIX}archive.raspbian.org/raspbian"
MIR_SEC="${MIR_REP}"
DISTRO="wheezy"
HAN_HOSTNAME=${HAN_HOSTNAME:-"han"}
HAN_USERNAME=${HAN_USERNAME:-"user"}
export http_proxy=${HAN_APT_CACHE}
lb config noauto \
-a amd64 \
-b hdd \
--mode debian \
--bootloader syslinux \
--debian-installer false \
-d ${DISTRO} \
--memtest none \
--apt-http-proxy "${HAN_APT_CACHE}" \
--parent-mirror-bootstrap ${MIR_REP} \
--parent-mirror-chroot-security ${MIR_SEC} \
--parent-mirror-binary ${MIR_REP} \
--parent-mirror-binary-security ${MIR_SEC} \
--mirror-bootstrap ${MIR_REP} \
--mirror-chroot-security ${MIR_SEC} \
--mirror-binary ${MIR_REP} \
--mirror-binary-security ${MIR_SEC} \
--keyring-packages "debian-archive-keyring" \
--firmware-binary true \
--firmware-chroot true \
--source false \
--apt-indices false \
--cache-packages false \
--archive-areas 'main contrib non-free' \
--bootappend-live "boot=live live-config username=${HAN_USERNAME} sudo openssh-server noeject quiet persistent console=tty0 console=ttyS0,115200n8 hostname=${HAN_HOSTNAME}" \
"${@}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment