From 287567a51366e9e2510f52193b182c8543971891 Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Fri, 25 Aug 2023 11:35:22 +1000 Subject: [PATCH] worker: Stop install script prompting to install kernel updates --- worker/install.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/worker/install.sh b/worker/install.sh index 30f227a..7a1a95b 100644 --- a/worker/install.sh +++ b/worker/install.sh @@ -2,8 +2,13 @@ # Initial install for all prerequisites for the project. # This makes it quicker to get each site up and running. -# Update the system -sudo apt update && sudo apt upgrade -y +# Stop kernel prompts +export DEBIAN_FRONTEND=noninteractive +export NEEDRESTART_MODE=a +echo "Dpkg::Options { \"--force-confdef\"; \"--force-confold\"; };" | sudo tee /etc/apt/apt.conf.d/local + +KERNEL_VERSION=$(uname -r) +sudo apt-mark hold linux-image-generic linux-headers-generic linux-generic linux-image-$KERNEL_VERSION linux-headers-$KERNEL_VERSION # Install Docker sudo apt install apt-transport-https ca-certificates curl software-properties-common python3-pip nginx -y