You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
kali-live-build/auto/config

76 lines
2.1 KiB
Plaintext

#!/bin/sh
# You can put local mirrors here if you want
kali_mirror=http://archive.kali.org/kali
kalisec_mirror=http://archive.kali.org/kali-security
### DO NOT EDIT THE REST OF THIS FILE ###
# live-build doesn't work if --parent-debian-distribution is unknown of
# debian-cd => we have to put a symlink so that it deals with kali like wheezy
if [ ! -e /usr/share/live/build/data/debian-cd/kali ]; then
echo "ERROR: Run this first"
echo "ln -sf wheezy /usr/share/live/build/data/debian-cd/kali"
exit 1
fi
# Detect target architecture
find_arch() {
while [ -n "$1" ]; do
case "$1" in
-a|--arch|--architecture|--architectures)
echo "$2"
return
;;
esac
shift
done
dpkg --print-architecture
}
arch=$(find_arch "$@")
case "$arch" in
amd64)
lb_opts="--debian-installer live"
;;
i386)
lb_opts="--debian-installer live --linux-flavours 686-pae"
;;
armel|armhf)
lb_opts="--binary-images hdd --binary-filesystem ext4 --chroot-filesystem none"
;;
*)
echo "WARNING: configuration not tested on arch $arch" >&2
lb_opts=""
;;
esac
public_kali_mirror=http://http.kali.org/kali
public_kalisec_mirror=http://security.kali.org/kali-security
lb config noauto \
--distribution "kali" \
--debian-installer-distribution "kali" \
--archive-areas "main contrib non-free" \
--bootstrap cdebootstrap \
--cdebootstrap-options "--keyring=/usr/share/keyrings/kali-archive-keyring.gpg --suite-config=wheezy" \
--keyring-packages kali-archive-keyring \
--updates false \
--backports false \
--source false \
--firmware-binary true \
--firmware-chroot true \
--mirror-bootstrap $kali_mirror \
--mirror-debian-installer $kali_mirror \
--mirror-chroot-security $kalisec_mirror \
--mirror-binary $public_kali_mirror \
--mirror-binary-security $public_kalisec_mirror \
--iso-application "Kali Linux" \
--iso-publisher "Kali" \
--iso-volume "Kali Live" \
--linux-packages linux-image \
--bootappend-live "boot=live config live-config.username=root hostname=kali" \
$lb_opts \
"$@"