2023-03-16 10:47:34 -01:00
|
|
|
#!/bin/bash
|
2023-04-25 17:08:13 +00:00
|
|
|
|
|
|
|
# SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
#
|
|
|
|
# SPDX-FileCopyrightText: 2023 PeppemrintOS Team (peppermintosteam@proton.me)
|
|
|
|
|
2023-03-16 10:47:34 -01:00
|
|
|
PATH="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
|
|
|
|
|
|
|
|
# Set the working folder variable
|
|
|
|
uchinanchu="$(pwd)"
|
|
|
|
|
|
|
|
# This cleanup might be better served in the BldHelper*.sh script.
|
|
|
|
# Create the build folder, move into it removing stale mountpoints and files there.
|
|
|
|
[ -e fusato ] && [ ! -d fusato ] && rm -f fusato || [ ! -e fusato ] && mkdir fusato
|
|
|
|
cd fusato
|
|
|
|
umount $(mount | grep "${PWD}/chroot" | tac | cut -f3 -d" ") 2>/dev/null
|
|
|
|
for i in ./* ./.build ; do [ $i = ./cache ] && continue || rm -rf $i ; done
|
|
|
|
|
|
|
|
|
|
|
|
#Define as configurações do Live Build
|
|
|
|
|
|
|
|
lb config noauto \
|
|
|
|
--binary-images iso-hybrid \
|
|
|
|
--architectures amd64 \
|
2023-04-25 17:08:13 +00:00
|
|
|
--distribution daedalus \
|
|
|
|
--initsystem sysvinit \
|
|
|
|
--archive-areas "main contrib non-free non-free-firmware" \
|
|
|
|
--mirror-bootstrap http://deb.devuan.org/merged \
|
|
|
|
--parent-mirror-bootstrap http://deb.devuan.org/merged \
|
|
|
|
--parent-mirror-chroot http://deb.devuan.org/merged \
|
|
|
|
--parent-mirror-chroot-security http://deb.devuan.org/merged \
|
|
|
|
--parent-mirror-binary http://deb.devuan.org/merged \
|
|
|
|
--parent-mirror-binary-security http://deb.devuan.org/merged \
|
|
|
|
--mirror-chroot http://deb.devuan.org/merged \
|
|
|
|
--mirror-chroot-security http://deb.devuan.org/merged \
|
|
|
|
--security false \
|
|
|
|
--updates false \
|
|
|
|
--backports false \
|
|
|
|
--firmware-chroot true \
|
2023-03-16 10:47:34 -01:00
|
|
|
--debian-installer live \
|
2023-04-25 17:08:13 +00:00
|
|
|
--debian-installer-distribution daedalus \
|
2023-03-16 10:47:34 -01:00
|
|
|
--debian-installer-gui true \
|
2023-04-25 17:08:13 +00:00
|
|
|
--parent-mirror-debian-installer http://repo.peppermintos.com/packages \
|
2023-03-16 10:47:34 -01:00
|
|
|
--iso-preparer "PeppermintOS-https://peppermintos.com/" \
|
|
|
|
--iso-publisher "Peppermint OS Team" \
|
2023-04-25 17:08:13 +00:00
|
|
|
--iso-volume "Peppermint" \
|
|
|
|
--image-name "PepOSserver" \
|
2023-04-30 16:53:15 +00:00
|
|
|
--debian-installer-preseedfile preseed.cfg \
|
2023-03-16 10:47:34 -01:00
|
|
|
--checksums sha512 \
|
|
|
|
--zsync false \
|
|
|
|
--win32-loader false \
|
2023-04-25 17:08:13 +00:00
|
|
|
|
2023-03-16 10:47:34 -01:00
|
|
|
"${@}"
|
|
|
|
|
|
|
|
|
|
|
|
# Setup the chroot structure
|
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.installer
|
|
|
|
mkdir -p $uchinanchu/fusato/config/config/package-lists
|
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.chroot
|
|
|
|
mkdir -p $uchinanchu/fusato/config/hooks/normal
|
|
|
|
mkdir -p $uchinanchu/fusato/config/archives
|
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.binary
|
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.chroot/boot/grub
|
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.chroot/etc/default
|
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.installer/usr/share
|
2023-04-25 17:08:13 +00:00
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.chroot/etc
|
2023-05-05 10:26:02 +00:00
|
|
|
mkdir -p $uchinanchu/fusato/config/includes.chroot/etc/firewalld/zones
|
2023-03-16 10:47:34 -01:00
|
|
|
|
|
|
|
# Install software
|
|
|
|
echo "#Install system packages.
|
2023-03-20 11:07:14 -01:00
|
|
|
zonefstoolspep
|
|
|
|
dmzonedtoolspep
|
|
|
|
libzbdpep1
|
|
|
|
sudo
|
2023-04-25 17:08:13 +00:00
|
|
|
task-ssh-server
|
|
|
|
task-web-server
|
2023-03-16 10:47:34 -01:00
|
|
|
sshguard
|
|
|
|
htop
|
2023-03-20 11:07:14 -01:00
|
|
|
fail2ban
|
|
|
|
whois
|
|
|
|
rkhunter
|
|
|
|
debsecan
|
2023-03-20 11:32:28 -01:00
|
|
|
net-tools
|
2023-04-25 17:08:13 +00:00
|
|
|
cockpit
|
|
|
|
cockpit-podman
|
|
|
|
podman
|
|
|
|
#libvirt
|
|
|
|
#samba
|
|
|
|
#cups
|
|
|
|
#gvfs-backends
|
2023-03-20 11:07:14 -01:00
|
|
|
|
|
|
|
|
2023-03-16 10:47:34 -01:00
|
|
|
" >> $uchinanchu/fusato/config/package-lists/package.list.chroot
|
|
|
|
|
|
|
|
# Copy single files and folder to the chroot
|
|
|
|
cp $uchinanchu/pepgrub/grub $uchinanchu/fusato/config/includes.chroot/etc/default
|
|
|
|
cp $uchinanchu/pephooks/normal/* $uchinanchu/fusato/config/hooks/normal
|
|
|
|
cp $uchinanchu/peprepo/* $uchinanchu/fusato/config/archives
|
2023-05-05 10:26:02 +00:00
|
|
|
cp $uchinanchu/pepfirewall/* $uchinanchu/fusato/config/includes.chroot/etc/firewalld/zones
|
2023-03-23 09:39:50 -01:00
|
|
|
cp $uchinanchu/pepinstaller/preseed/preseed.cfg $uchinanchu/fusato/config/includes.installer
|
2023-03-16 10:47:34 -01:00
|
|
|
|
|
|
|
|
|
|
|
# Copy recursive files and sub-directories, containing symlinks.
|
|
|
|
cp -r $uchinanchu/peploadersplash/boot $uchinanchu/fusato/config/includes.binary
|
|
|
|
cp -r $uchinanchu/peploadersplash/isolinux $uchinanchu/fusato/config/includes.binary
|
|
|
|
cp -r $uchinanchu/pepgrub/themes $uchinanchu/fusato/config/includes.chroot/boot/grub
|
2023-03-20 11:07:14 -01:00
|
|
|
cp -r $uchinanchu/pepinstaller/graphics $uchinanchu/fusato/config/includes.installer/usr/share
|
|
|
|
cp -r $uchinanchu/pepinstaller/themes $uchinanchu/fusato/config/includes.installer/usr/share
|
2023-03-16 10:47:34 -01:00
|
|
|
|
|
|
|
lb build
|