live-installer: ensure sources.list is configured
By default, when you don't have any network or when you didn't enable a network mirror, your sources.list is empty. We don't want this so we hook into the finish-install step to make sure to set it up if it's empty.merge-requests/16/head
parent
830d863fa6
commit
25d0c1004b
@ -0,0 +1,17 @@
|
||||
#!/bin/sh
|
||||
|
||||
if grep -q '^deb ' /target/etc/apt/sources.list; then
|
||||
echo "INFO: sources.list is configured, everything is fine"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
echo "INFO: sources.list is empty, setting up a default one for Kali"
|
||||
|
||||
cat >/target/etc/apt/sources.list <<END
|
||||
# See https://www.kali.org/docs/general-use/kali-linux-sources-list-repositories/
|
||||
deb http://http.kali.org/kali kali-rolling main contrib non-free
|
||||
|
||||
# Additional line for source packages
|
||||
# deb-src http://http.kali.org/kali kali-rolling main contrib non-free
|
||||
END
|
||||
in-target apt-get update || true
|
Loading…
Reference in New Issue