Merge branch 'master' into consistency
# Conflicts: # .gitignore # banana-pi.sh # banana-pro.sh # beaglebone-black.sh # chromebook-exynos.sh # chromebook-nyan.sh # common.d/builder.txt.example # common.d/compress_img.sh # common.d/variables.sh # cubieboard2.sh # cubietruck.sh # cubox-i4pro.sh # cubox.sh # gateworks-newport.sh # gateworks-ventana.sh # mini-x.sh # nanopc-t.sh # nanopi-neo-plus2-minimal.sh # nanopi-neo-plus2.sh # nanopi2.sh # odroid-c.sh # odroid-c2.sh # odroid-u2.sh # odroid-xu3.sh # pinebook-pro.sh # pinebook.sh # riotboard.sh # rpi-64bit-minimal.sh # rpi-64bit.sh # rpi.sh # rpi0w-minimal.sh # rpi0w-p4wnp1-aloa.sh # rpi0w-pitail.sh # rpi0w.sh # rpi1.sh # trimslice.sh # usb-armory-mki.sh # usb-armory-mkii.sh # utilite-pro.sh
This commit is contained in:
@@ -139,7 +139,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -202,6 +202,10 @@ echo "Rsyncing rootfs to image file"
|
||||
rsync -HPavz -q ${work_dir}/ ${basedir}/root/
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l ${rootp}
|
||||
|
||||
@@ -139,7 +139,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -188,6 +188,10 @@ log "Rsyncing rootfs into image file" green
|
||||
rsync -HPavz -q ${work_dir}/ ${basedir}/root/
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Unmount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount ${rootp}
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -494,9 +494,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -140,11 +140,11 @@ elif itest.s "x${dtype}" == "xmmc" ; then
|
||||
elif itest.s "x${dtype}" == "xusb" ; then
|
||||
echo "Booting from USB Mass Storage..."
|
||||
setenv root "root=/dev/sda1 rootwait"
|
||||
setenv fsload "ext3load $dtype 0:1"
|
||||
setenv fsload "ext4load $dtype 0:1"
|
||||
elif itest.s "x${dtype}" == "xsata" ; then
|
||||
echo "Booting from SATA..."
|
||||
setenv root "root=/dev/sda1 rootwait"
|
||||
setenv fsload "ext3load $dtype 0:1"
|
||||
setenv fsload "ext4load $dtype 0:1"
|
||||
setenv rd_addr # ramdisk not needed for IMX6 AHCI SATA
|
||||
fi
|
||||
|
||||
|
||||
@@ -189,7 +189,7 @@ iface lo inet loopback
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -695,9 +695,7 @@ mkdir -p "${basedir}"/root
|
||||
mount ${rootp} "${basedir}"/root
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -189,7 +189,7 @@ iface lo inet loopback
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -599,9 +599,7 @@ mkdir -p "${basedir}"/root
|
||||
mount ${rootp} "${basedir}"/root
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -193,7 +193,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -311,9 +311,7 @@ if [[ ! -z "${4}" || ! -z "${5}" ]]; then
|
||||
suite=${5}
|
||||
fi
|
||||
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Define sources.list
|
||||
cat << EOF > ${work_dir}/etc/apt/sources.list
|
||||
|
||||
@@ -1,5 +1,56 @@
|
||||
#mirror="http://kali.download/kali"
|
||||
# Version Kali release
|
||||
#version=${version:-$(cat .release)}
|
||||
|
||||
# Custom hostname variable
|
||||
#hostname=kali
|
||||
|
||||
# Choose a locale
|
||||
#locale="en_US.UTF-8"
|
||||
|
||||
# Free space added to the rootfs in MiB
|
||||
#free_space="300"
|
||||
|
||||
# /boot partition in MiB
|
||||
#bootsize="128"
|
||||
|
||||
# Select compression, xz or none
|
||||
#compress="xz"
|
||||
|
||||
# Choose filesystem format to format ( ext3 or ext4 )
|
||||
fstype="ext4"
|
||||
|
||||
# Disable IPV6 ( yes or no)
|
||||
#disable_ipv6="yes"
|
||||
|
||||
# Make SWAP ( yes or no)
|
||||
#swap="no"
|
||||
|
||||
# DNS server
|
||||
#nameserver="8.8.8.8"
|
||||
|
||||
# To limit the number of CPU cores to use during compression
|
||||
# Use 0 for unlimited CPU cores, -1 to subtract 1 cores from the total
|
||||
#cpu_cores="4"
|
||||
|
||||
# To limit the CPU usage during compression
|
||||
# 0 or 100 No limit, 10 = percentage use, 50, 75, 90, etc.
|
||||
#cpu_limit="85"
|
||||
|
||||
# If you have your own preferred mirrors, set them here.
|
||||
#mirror="http://http.kali.org/kali"
|
||||
#replace_mirror="http://http.kali.org/kali"
|
||||
#suite="kali-last-snapshot"
|
||||
|
||||
# Use packages from the listed components of the archive.
|
||||
#components="main,contrib,non-free"
|
||||
|
||||
# Suite to use, valid options are:
|
||||
# kali-rolling, kali-dev, kali-dev-only, kali-last-snapshot
|
||||
#suite="kali-rolling"
|
||||
#replace_suite="kali-rolling"
|
||||
#imagename="kali-linux-nightly-${hw_model}-${variant}-$(date +%F)"
|
||||
|
||||
# Default file name
|
||||
# On the RPi 3 script, this would result in
|
||||
# "kali-linux-202X-WXX-rpi4-nexmon-arm64" for the default filename.
|
||||
# For release builds from Kali, the requirements are that it start with kali-linuxi
|
||||
# and end with the architecture.
|
||||
#imagename="kali-linux-$(date +%Y)-W$(date +%U)-${hw_model}-${variant}"
|
||||
|
||||
@@ -4,7 +4,7 @@ log "compress image" green
|
||||
|
||||
if [ "${compress:=}" = xz ]; then
|
||||
log "Compressing file: $(tput sgr0) ${imagename:=}.img" green
|
||||
if [ "$(arch)" == 'x86_64' ]; then
|
||||
if [ "$(arch)" == 'x86_64' ] || [ "$(arch)" == 'aarch64' ]; then
|
||||
limit_cpu pixz -p "${num_cores:=}" "${image_dir:=}"/"${imagename}".img # -p Nº cpu cores use
|
||||
else
|
||||
xz --memlimit-compress=50% -T "$num_cores" "${image_dir}"/"${imagename}".img # -T Nº cpu cores use
|
||||
|
||||
@@ -40,13 +40,15 @@ rpi_pkgs="fake-hwclock ntpdate u-boot-tools"
|
||||
gpio_pkgs="i2c-tools python3-configobj python3-pip python3-requests python3-rpi.gpio python3-smbus"
|
||||
|
||||
extra="$custom_kernel_pkgs"
|
||||
packages="$common_pkgs $cli_tools_pkgs $services"
|
||||
|
||||
# add extra_custom_pkgs, that can be a global variable
|
||||
packages="$common_pkgs $cli_tools_pkgs $services $extra_custom_pkgs"
|
||||
|
||||
if [[ "$hw_model" == *rpi* ]]; then
|
||||
extra+=" $gpio_pkgs $rpi_pkgs"
|
||||
fi
|
||||
if [[ "$variant" == *lite* ]]; then
|
||||
packages="$common_min_pkgs $cli_min_tools $services"
|
||||
packages="$common_min_pkgs $cli_min_tools $services $extra_custom_pkgs"
|
||||
fi
|
||||
|
||||
third_stage_pkgs="binutils ca-certificates console-common console-setup locales libterm-readline-gnu-perl git wget curl"
|
||||
|
||||
@@ -48,6 +48,8 @@ components="main,contrib,non-free"
|
||||
kaligit="https://gitlab.com/kalilinux"
|
||||
# GitHub raw URL
|
||||
githubraw="https://raw.githubusercontent.com"
|
||||
# DNS server
|
||||
nameserver=${nameserver:-"8.8.8.8"}
|
||||
# workaround for LP: #520465
|
||||
export MALLOC_CHECK_=0
|
||||
# Proxy
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -415,9 +415,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -415,9 +415,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -373,9 +373,7 @@ mkdir -p "${basedir}"/root
|
||||
mount ${rootp} "${basedir}"/root
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
6
cubox.sh
6
cubox.sh
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -428,9 +428,7 @@ mkdir -p "${basedir}"/root
|
||||
mount ${rootp} "${basedir}"/root
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -132,7 +132,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -231,6 +231,9 @@ echo "UUID=$UUID / $fstype errors=remount-ro 0 1" >> ${wo
|
||||
log "Rsyncing rootfs into image file" green
|
||||
rsync -HPavz -q ${work_dir}/ ${basedir}/root/
|
||||
sync
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
|
||||
@@ -130,7 +130,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -244,7 +244,10 @@ EOF
|
||||
|
||||
log "Rsyncing rootfs into image file" green
|
||||
rsync -HPavz -q "${work_dir}"/ "${basedir}"/root/
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -366,9 +366,7 @@ mkdir -p "${basedir}"/root
|
||||
mount ${rootp} "${basedir}"/root
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -132,7 +132,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -274,6 +274,10 @@ sync
|
||||
|
||||
cd "${current_dir}/"
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -203,7 +203,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -377,6 +377,10 @@ sync
|
||||
|
||||
cd "${current_dir}/"
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -217,7 +217,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -391,6 +391,10 @@ sync
|
||||
|
||||
cd "${current_dir}/"
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -197,7 +197,7 @@ alias net-pf-10 off
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -468,9 +468,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -611,9 +611,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -144,7 +144,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -280,6 +280,10 @@ sync
|
||||
|
||||
cd "${current_dir}/"
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -457,9 +457,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
echo "Rsyncing rootfs into image file"
|
||||
rsync -HPavz -q ${work_dir}/ ${basedir}/root/
|
||||
|
||||
@@ -149,7 +149,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -279,7 +279,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount "${bootp}" "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
log "/etc/fstab" green
|
||||
@@ -302,6 +302,10 @@ sh sd_fusing.sh ${loopdevice}
|
||||
|
||||
cd "${current_dir}/"
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -141,7 +141,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -332,6 +332,10 @@ dd if=${current_dir}/bsp/bootloader/pinebook-pro/trust.img of=${loopdevice} seek
|
||||
|
||||
#TARGET="/usr/lib/u-boot/pinebook-pro-rk3399" /usr/bin/u-boot-install-rockchip ${loopdevice}
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -208,7 +208,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -284,6 +284,10 @@ sync
|
||||
|
||||
cd "${current_dir}/"
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -194,7 +194,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -439,9 +439,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -92,10 +92,6 @@ wget -qO /etc/apt/trusted.gpg.d/kali_pi-archive-keyring.gpg https://re4son-kerne
|
||||
eatmydata apt-get update
|
||||
eatmydata apt-get install -y kalipi-kernel kalipi-bootloader kalipi-re4son-firmware kalipi-kernel-headers firmware-raspberry kalipi-config kalipi-tft-config
|
||||
|
||||
# Regenerated the shared-mime-info database on the first boot
|
||||
# since it fails to do so properly in a chroot
|
||||
systemctl enable smi-hack
|
||||
|
||||
# Copy script rpi-resizerootfs
|
||||
install -m755 /bsp/scripts/rpi-resizerootfs /usr/sbin/
|
||||
|
||||
@@ -118,10 +114,7 @@ cd /root
|
||||
apt download -o APT::Sandbox::User=root ca-certificates 2>/dev/null
|
||||
|
||||
# Set a REGDOMAIN. This needs to be done or wireless doesn't work correctly on the RPi 3B+
|
||||
sed -i -e 's/REGDOM.*/REGDOMAIN=00/g' /etc/default/crda
|
||||
|
||||
# Enable login over serial
|
||||
echo "T0:23:respawn:/sbin/agetty -L ttyAMA0 115200 vt100" >> /etc/inittab
|
||||
sed -i -e 's/REGDOM.*/REGDOMAIN=00/g' /etc/default/crda || true
|
||||
|
||||
# Try and make the console a bit nicer
|
||||
# Set the terminus font for a bit nicer display
|
||||
@@ -156,7 +149,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -210,6 +203,10 @@ log "Rsyncing rootfs into image file (/boot)" green
|
||||
rsync -rtx -q "${work_dir}"/boot "${basedir}"/root
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${bootp}"
|
||||
|
||||
@@ -150,7 +150,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -204,6 +204,10 @@ log "Rsyncing rootfs into image file (/boot)" green
|
||||
rsync -rtx -q "${work_dir}"/boot "${basedir}"/root
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${bootp}"
|
||||
|
||||
6
rpi.sh
6
rpi.sh
@@ -150,7 +150,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Reload sources.list
|
||||
@@ -204,6 +204,10 @@ log "Rsyncing rootfs into image file (/boot)" green
|
||||
rsync -rtx -q "${work_dir}"/boot "${basedir}"/root
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${bootp}"
|
||||
|
||||
@@ -146,7 +146,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
|
||||
@@ -45,6 +45,8 @@ mirror=${mirror:-"http://http.kali.org/kali"}
|
||||
kaligit="https://gitlab.com/kalilinux"
|
||||
# GitHub raw URL
|
||||
githubraw="https://raw.githubusercontent.com"
|
||||
# DNS server
|
||||
nameserver=${nameserver:-"8.8.8.8"}
|
||||
|
||||
# Check EUID=0 you can run any binary as root
|
||||
if [[ $EUID -ne 0 ]]; then
|
||||
@@ -88,7 +90,7 @@ fi
|
||||
components="main,contrib,non-free"
|
||||
arm="fake-hwclock ntpdate u-boot-tools"
|
||||
tools="aircrack-ng crunch cewl dnsrecon dnsutils ethtool exploitdb hydra medusa metasploit-framework ncrack nmap passing-the-hash proxychains recon-ng sqlmap tcpdump theharvester tor tshark usbutils whois windows-binaries winexe wpscan"
|
||||
base="apt-transport-https apt-utils console-setup e2fsprogs firmware-linux firmware-realtek firmware-atheros ifupdown initramfs-tools iw kali-defaults man-db mlocate netcat-traditional net-tools parted psmisc rfkill screen snmpd snmp tftp tmux unrar usbutils vim wget zerofree"
|
||||
base="apt-transport-https apt-utils console-setup e2fsprogs firmware-linux firmware-realtek firmware-atheros ifupdown initramfs-tools iw kali-defaults man-db mlocate netcat-traditional net-tools parted psmisc rfkill screen snmpd snmp sudo tftp tmux unrar usbutils vim wget zerofree"
|
||||
services="apache2 atftpd openssh-server openvpn"
|
||||
# haveged: assure enough entropy data for hostapd on startup
|
||||
# avahi-daemon: allow mDNS resolution (apple bonjour) by remote hosts
|
||||
@@ -195,7 +197,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > ${work_dir}/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -369,7 +371,7 @@ touch "${work_dir}"/etc/machine-id
|
||||
rm -f "${work_dir}"/var/lib/dbus/machine-id || true
|
||||
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > ${work_dir}/etc/resolv.conf
|
||||
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
if [ -n "$proxy_url" ]; then
|
||||
@@ -568,7 +570,7 @@ mount ${bootp} ${basedir}/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > kali-${architecture}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
nameserver ${nameserver}
|
||||
EOF
|
||||
|
||||
# Because of the p4wnp1 script, we set the hostname down here, instead of using the machine name
|
||||
@@ -590,6 +592,10 @@ rsync -HPavz -q --exclude boot ${work_dir}/ ${basedir}/root/
|
||||
rsync -rtx -q ${work_dir}/boot ${basedir}/root
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Unmount partitions
|
||||
umount ${bootp}
|
||||
umount ${rootp}
|
||||
|
||||
@@ -43,6 +43,8 @@ mirror=${mirror:-"http://http.kali.org/kali"}
|
||||
kaligit="https://gitlab.com/kalilinux"
|
||||
# GitHub raw URL
|
||||
githubraw="https://raw.githubusercontent.com"
|
||||
# DNS server
|
||||
nameserver=${nameserver:-"8.8.8.8"}
|
||||
|
||||
# Check EUID=0 you can run any binary as root
|
||||
if [[ $EUID -ne 0 ]]; then
|
||||
@@ -442,7 +444,7 @@ history -c
|
||||
EOF
|
||||
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > ${work_dir}/etc/resolv.conf
|
||||
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
if [ -n "$proxy_url" ]; then
|
||||
@@ -528,6 +530,10 @@ rsync -HPavz -q --exclude boot ${work_dir}/ ${basedir}/root/
|
||||
rsync -rtx -q ${work_dir}/boot ${basedir}/root
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Unmount partitions
|
||||
umount -l ${bootp}
|
||||
umount -l ${rootp}
|
||||
|
||||
8
rpi0w.sh
8
rpi0w.sh
@@ -86,7 +86,7 @@ install -m755 /bsp/scripts/monstop /usr/bin/
|
||||
echo "deb http://http.re4son-kernel.com/re4son kali-pi main" > /etc/apt/sources.list.d/re4son.list
|
||||
wget -qO /etc/apt/trusted.gpg.d/kali_pi-archive-keyring.gpg https://re4son-kernel.com/keys/http/kali_pi-archive-keyring.gpg
|
||||
eatmydata apt-get update
|
||||
eatmydata apt-get install -y kalipi-kernel kalipi-bootloader kalipi-re4son-firmware kalipi-kernel-headers kalipi-config kalipi-tft-config firmware-raspberry
|
||||
eatmydata apt-get install -y kalipi-kernel kalipi-bootloader kalipi-re4son-firmware kalipi-kernel-headers kalipi-config kalipi-tft-config firmware-raspberry pi-bluetooth
|
||||
|
||||
# Copy script rpi-resizerootfs
|
||||
install -m755 /bsp/scripts/rpi-resizerootfs /usr/sbin/
|
||||
@@ -151,7 +151,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -205,6 +205,10 @@ log "Rsyncing rootfs into image file (/boot)" green
|
||||
rsync -rtx -q "${work_dir}"/boot "${basedir}"/root
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${bootp}"
|
||||
|
||||
6
rpi1.sh
6
rpi1.sh
@@ -149,7 +149,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -203,6 +203,10 @@ log "Rsyncing rootfs into image file (/boot)" green
|
||||
rsync -rtx -q "${work_dir}"/boot "${basedir}"/root
|
||||
sync
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${bootp}"
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -410,9 +410,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -191,7 +191,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -545,9 +545,7 @@ mkdir -p "${basedir}"/root
|
||||
mount ${rootp} "${basedir}"/root
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
@@ -174,7 +174,7 @@ set_locale "$locale"
|
||||
include clean_system
|
||||
trap clean_build ERR SIGTERM SIGINT
|
||||
# Define DNS server after last running systemd-nspawn
|
||||
echo "nameserver 8.8.8.8" >"${work_dir}"/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
# Disable the use of http proxy in case it is enabled
|
||||
disable_proxy
|
||||
# Mirror & suite replacement
|
||||
@@ -264,6 +264,10 @@ dd if=u-boot.imx of=${loopdevice} bs=512 seek=2 conv=fsync
|
||||
|
||||
cd "${current_dir}/"
|
||||
|
||||
# Flush buffers and bytes - this is nicked from the Devuan arm-sdk.
|
||||
blockdev --flushbufs "${loopdevice}"
|
||||
python -c 'import os; os.fsync(open("'${loopdevice}'", "r+b"))'
|
||||
|
||||
# Umount filesystem
|
||||
log "Umount filesystem" green
|
||||
umount -l "${rootp}"
|
||||
|
||||
@@ -192,7 +192,7 @@ iface eth0 inet dhcp
|
||||
EOF
|
||||
|
||||
# DNS server
|
||||
echo "nameserver 8.8.8.8" > ${work_dir}/etc/resolv.conf
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Copy directory bsp into build dir
|
||||
cp -rp bsp ${work_dir}
|
||||
@@ -453,9 +453,7 @@ mkdir -p "${basedir}"/root/boot
|
||||
mount ${bootp} "${basedir}"/root/boot
|
||||
|
||||
# We do this down here to get rid of the build system's resolv.conf after running through the build
|
||||
cat << EOF > ${work_dir}/etc/resolv.conf
|
||||
nameserver 8.8.8.8
|
||||
EOF
|
||||
echo "nameserver ${nameserver}" > "${work_dir}"/etc/resolv.conf
|
||||
|
||||
# Create an fstab so that we don't mount / read-only
|
||||
UUID=$(blkid -s UUID -o value ${rootp})
|
||||
|
||||
Reference in New Issue
Block a user