Add minimal image recipe
This commit is contained in:
parent
074719ff2c
commit
1ef8161db5
12 changed files with 942 additions and 0 deletions
32
src/recipes/minimal/hook/customize.sh
Executable file
32
src/recipes/minimal/hook/customize.sh
Executable file
|
@ -0,0 +1,32 @@
|
|||
#!/bin/bash
|
||||
|
||||
printf "Customize hook script for mmdebstrap %s\n\n" "$RECIPE"
|
||||
|
||||
printf "Remove root password\n"
|
||||
#echo "root:root" | chpasswd
|
||||
passwd -d root
|
||||
|
||||
printf "Add MNT repository and key\n"
|
||||
chroot $1 apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 376511EB67AD7BAF
|
||||
echo "deb https://mntre.com/reform-debian sid/" | chroot $1 tee /etc/apt/sources.list.d/mntre.list
|
||||
chroot $1 apt update
|
||||
|
||||
printf "Install MNT packages\n"
|
||||
chroot $1 apt install -y reform-tools reform-handbook
|
||||
|
||||
source="${RECIPE}/hook/data/overlay"
|
||||
printf "Sync overlay directory from %s to %s\n" "$source" "$1"
|
||||
if [ -d $source ]
|
||||
then
|
||||
printf " -> source exist\n"
|
||||
cp -Raf ${RECIPE}/hook/data/overlay/* $1
|
||||
else
|
||||
printf "Can't find %s directory\n" "$source"
|
||||
fi
|
||||
|
||||
#Start hw setur service
|
||||
chroot $1 systemctl enable reform-hw-setup.service
|
||||
#mask hibernation / sleep target
|
||||
chroot $1 systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
|
||||
|
||||
exit 0
|
Loading…
Add table
Add a link
Reference in a new issue