From 373c64e95fc45daa5163d6fe1cc8f0eb020540d4 Mon Sep 17 00:00:00 2001 From: t3chn0m4g3 Date: Thu, 15 Nov 2018 11:55:37 +0000 Subject: [PATCH] remove interactions from update allowing for rolling releases --- iso/installer/install.sh | 4 +++- iso/preseed/tpot.seed | 2 +- update.sh | 10 ++++++---- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/iso/installer/install.sh b/iso/installer/install.sh index 0e20480a..9eb82848 100755 --- a/iso/installer/install.sh +++ b/iso/installer/install.sh @@ -126,7 +126,7 @@ fi # Let's check if all dependencies are met function fuGET_DEPS { -local myPACKAGES="apache2-utils apparmor apt-transport-https aufs-tools bash-completion build-essential ca-certificates cgroupfs-mount cockpit cockpit-docker curl dialog dnsutils docker.io docker-compose dstat ethtool fail2ban genisoimage git glances grc html2text htop ifupdown iptables iw jq libcrack2 libltdl7 lm-sensors man mosh multitail net-tools npm ntp openssh-server openssl pass prips syslinux psmisc pv python-pip unattended-upgrades unzip vim wireless-tools wpasupplicant" +local myPACKAGES="apache2-utils apparmor apt-transport-https aufs-tools bash-completion build-essential ca-certificates cgroupfs-mount cockpit cockpit-docker curl debconf-utils dialog dnsutils docker.io docker-compose dstat ethtool fail2ban genisoimage git glances grc html2text htop ifupdown iptables iw jq libcrack2 libltdl7 lm-sensors man mosh multitail net-tools npm ntp openssh-server openssl pass prips syslinux psmisc pv python-pip unattended-upgrades unzip vim wireless-tools wpasupplicant" add-apt-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) main universe restricted multiverse" echo echo "### Getting update information." @@ -136,6 +136,8 @@ echo echo "### Upgrading packages." echo # Downlaod and upgrade packages, but silently keep existing configs +echo "docker.io docker.io/restart boolean true" | debconf-set-selections -v +echo "debconf debconf/frontend select noninteractive" | debconf-set-selections -v apt-get dist-upgrade -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" --force-yes echo echo "### Installing T-Pot dependencies." diff --git a/iso/preseed/tpot.seed b/iso/preseed/tpot.seed index 4fa1d5f2..e9eebd3c 100755 --- a/iso/preseed/tpot.seed +++ b/iso/preseed/tpot.seed @@ -101,7 +101,7 @@ tasksel tasksel/first multiselect ubuntu-server ######################## ### Package Installation ######################## -d-i pkgsel/include string apache2-utils apparmor apt-transport-https aufs-tools bash-completion build-essential ca-certificates cgroupfs-mount cockpit cockpit-docker curl dialog dnsutils docker.io docker-compose dstat ethtool fail2ban genisoimage git glances grc html2text htop ifupdown iptables iw jq libcrack2 libltdl7 lm-sensors man mosh multitail net-tools npm ntp openssh-server openssl pass prips syslinux psmisc pv python-pip unzip vim wireless-tools wpasupplicant +d-i pkgsel/include string apache2-utils apparmor apt-transport-https aufs-tools bash-completion build-essential ca-certificates cgroupfs-mount cockpit cockpit-docker curl debconf-utils dialog dnsutils docker.io docker-compose dstat ethtool fail2ban genisoimage git glances grc html2text htop ifupdown iptables iw jq libcrack2 libltdl7 lm-sensors man mosh multitail net-tools npm ntp openssh-server openssl pass prips syslinux psmisc pv python-pip unzip vim wireless-tools wpasupplicant ################# ### Update Policy diff --git a/update.sh b/update.sh index 9a5dcd4f..344c59ac 100755 --- a/update.sh +++ b/update.sh @@ -157,16 +157,18 @@ echo } function fuUPDATER () { -local myPACKAGES="apache2-utils apparmor apt-transport-https aufs-tools bash-completion build-essential ca-certificates cgroupfs-mount cockpit cockpit-docker curl dialog dnsutils docker.io docker-compose dstat ethtool fail2ban genisoimage git glances grc html2text htop ifupdown iptables iw jq libcrack2 libltdl7 lm-sensors man mosh multitail net-tools npm ntp openssh-server openssl pass prips syslinux psmisc pv python-pip unattended-upgrades unzip vim wireless-tools wpasupplicant" +local myPACKAGES="apache2-utils apparmor apt-transport-https aufs-tools bash-completion build-essential ca-certificates cgroupfs-mount cockpit cockpit-docker curl debconf-utils dialog dnsutils docker.io docker-compose dstat ethtool fail2ban genisoimage git glances grc html2text htop ifupdown iptables iw jq libcrack2 libltdl7 lm-sensors man mosh multitail net-tools npm ntp openssh-server openssl pass prips syslinux psmisc pv python-pip unattended-upgrades unzip vim wireless-tools wpasupplicant" echo "### Now upgrading packages ..." apt-get -y autoclean apt-get -y autoremove apt-get update apt-get -y install $myPACKAGES -# Some updates require interactive attention, you can override that for unattended upgrades. -# Be warned, this can easily break your system. + +# Some updates require interactive attention, and the following settings will override that. +echo "docker.io docker.io/restart boolean true" | debconf-set-selections -v +echo "debconf debconf/frontend select noninteractive" | debconf-set-selections -v apt-get dist-upgrade -y -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confold" --force-yes -#apt-get -y dist-upgrade + npm install "https://github.com/taskrabbit/elasticsearch-dump" -g pip install --upgrade pip hash -r