mirror of
https://github.com/kforney/pentest-distro-builder.git
synced 2024-11-25 01:35:24 -07:00
Ask for repository.
This commit is contained in:
parent
e6cdfc687f
commit
10dab8f720
1 changed files with 30 additions and 4 deletions
34
runme.sh
34
runme.sh
|
@ -21,9 +21,20 @@ DESKTOP=$(whiptail --backtitle "Pentest Build Script" --title "Desktop Environme
|
|||
"cinnamon" "Cinnamon Desktop Environment" \
|
||||
"kde" "K Desktop Environment" 3>&1 1>&2 2>&3)
|
||||
|
||||
REPO=$(whiptail --backtitle "Pentest Build Script" --title "Repository" --menu "Which repository are you going to use?" 10 60 2 \
|
||||
"default" "The distribution's default repository" \
|
||||
"local" "A repository hosted on your local network" 3>&1 1>&2 2>&3)
|
||||
|
||||
if [ $REPO == "local" ];
|
||||
then
|
||||
REPO=$(whiptail --backtitle "Pentest Build Script" --title "Local Repository" --inputbox "What is the IP address of your local repository?" \
|
||||
10 60 3>&1 1>&2 2>&3)
|
||||
fi
|
||||
|
||||
if (whiptail --backtitle "Pentest Build Script" --title "Confirmation" --yesno "We're going to build:
|
||||
Distribution: $DISTRO
|
||||
Desktop Environment: $DESKTOP
|
||||
Repository: $REPO
|
||||
Shall we proceed?" 10 50)
|
||||
then
|
||||
whiptail --backtitle "Pentest Build Script" --title "Build Time!" --msgbox "This will take a while. Press OK to proceed." 8 30
|
||||
|
@ -47,11 +58,16 @@ Kali)
|
|||
cp config/02-unattended-boot.binary ./build/live-build-config/kali-config/common/includes.installer/
|
||||
cp config/preseed.cfg ./build/live-build-config/kali-config/common/includes.installer/
|
||||
cp config/software.list.chroot ./build/live-build-config/kali-config/variant-$DESKTOP/
|
||||
|
||||
if [ $REPO != "default" ];
|
||||
then
|
||||
sed -i 's/archive.kali.org/$REPO/g' ./build/live-build-config/auto/config
|
||||
fi
|
||||
|
||||
cd build/live-build-config
|
||||
pause "Are you all ready to build? Hit enter when you're ready (this will take a while...)"
|
||||
./build.sh --distribution kali-rolling --variant $DESKTOP --verbose
|
||||
whiptail --backtitle "Pentest Build Script" --title "Finished" --msgbox "Fingers crossed there were no errors... Your image should be done!" 7 70
|
||||
exit 0
|
||||
cp images/*.iso ../../images/
|
||||
;;
|
||||
Parrot)
|
||||
cp -rv ./modules/parrot-build ./build/
|
||||
|
@ -59,10 +75,20 @@ Parrot)
|
|||
cp ./debs/*.deb build/parrot-build/templates/parrot-variant-$DESKTOP/packages.chroot/
|
||||
cp -rv filesystem/* ./build/parrot-build/templates/common/includes.chroot/
|
||||
cp config/software.list.chroot ./build/parrot-build/templates/parrot-variant-$DESKTOP/
|
||||
|
||||
if [ $REPO != "default" ];
|
||||
then
|
||||
sed -i "s|archive.parrotsec.org|$REPO|g" ./build/parrot-build/auto/config
|
||||
sed -i "s|deb.parrotsec.org|$REPO|g" ./build/parrot-build/templates/common/archives/parrot.list
|
||||
fi
|
||||
|
||||
cd build/parrot-build
|
||||
pause "Are you all ready to build? Hit enter when you're ready (this will take a while...)"
|
||||
./build.sh build variant-$DESKTOP amd64
|
||||
whiptail --backtitle "Pentest Build Script" --title "Finished" --msgbox "Fingers crossed there were no errors... Your image should be done!" 7 70
|
||||
exit 0
|
||||
cp *.iso ../../images/
|
||||
;;
|
||||
esac
|
||||
|
||||
whiptail --backtitle "Pentest Build Script" --title "Finished" --msgbox "Fingers crossed there were no errors... Your image should be done!" 7 70
|
||||
|
||||
exit 0
|
||||
|
|
Loading…
Reference in a new issue