Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

apt-get with quiet option is still noisy

Tags:

bash

apt-get

Trying to use apt-get in a script, so I'm using the apt-get -qq -y option, as I want to have my install script show something like...

Installing SUDO....DONE

But for some reason apt-get is still producing lots of output, with this option, which means I end up getting...

Installing SUDO....
Selecting previously unselected package sudo.
(Reading database ... 48056 files and directories currently installed.)
Preparing to unpack .../sudo_1.8.10p3-1+deb8u5_amd64.deb ...
Unpacking sudo (1.8.10p3-1+deb8u5) ...
Processing triggers for man-db (2.7.0.2-5) ...
Processing triggers for systemd (215-17+deb8u5) ...
Setting up sudo (1.8.10p3-1+deb8u5) ...
DONE

So my install script just looks messy for a basic package install, let alone for all the other packages.

Am I missing something?

like image 829
Guy Park Avatar asked Oct 04 '18 08:10

Guy Park


1 Answers

Try to run sudo DEBIAN_FRONTEND=noninteractive apt-get install -qq sudo < /dev/null > /dev/null

Source: https://peteris.rocks/blog/quiet-and-unattended-installation-with-apt-get/

like image 114
A.Newgate Avatar answered Oct 09 '22 04:10

A.Newgate