Remove postinst on cron and beanstalkd.

This commit is contained in:
Buster "Silver Eagle" Neece 2021-12-13 02:11:37 -06:00
parent c6953834a7
commit 834581e4d8
No known key found for this signature in database
GPG Key ID: 9FC8B9E008872109
3 changed files with 21 additions and 11 deletions

View File

@ -2,3 +2,21 @@ export LC_ALL=C
export DEBIAN_FRONTEND=noninteractive
minimal_apt_get_install='apt-get install -y --no-install-recommends'
install_without_postinst() {
local PACKAGE
PACKAGE=$1
mkdir -p /tmp/install_$PACKAGE
cd /tmp/install_$PACKAGE
apt-get download $PACKAGE
dpkg --unpack $PACKAGE*.deb
rm -f /var/lib/dpkg/info/$PACKAGE.postinst
dpkg --configure $PACKAGE
apt-get install -yf #To fix dependencies
cd /
rm -rf /tmp/install_$PACKAGE
}

View File

@ -3,11 +3,6 @@ set -e
source /bd_build/buildconfig
set -x
apt-get update
$minimal_apt_get_install netbase
# Prevent systemd auto-startup
ln -s /dev/null /etc/systemd/system/beanstalkd.service
echo "STARTTIME=30" > /etc/default/beanstalkd
$minimal_apt_get_install -o Dpkg::Options::="--force-confdef" beanstalkd
install_without_postinst beanstalkd

View File

@ -3,10 +3,7 @@ set -e
source /bd_build/buildconfig
set -x
# Prevent systemd auto-startup
ln -s /dev/null /etc/systemd/system/cron.service
$minimal_apt_get_install cron
install_without_postinst cron
chmod 600 /etc/crontab