I am working on some bash scripts to configure various packages the way I need them. When installing Debian 'unattended-upgrades' normally one of the user intervention required is to run *user@hostname:~# dpkg-reconfigure -plow unattended-upgrades*
to generate the /etc/apt/apt.conf.d/20auto-upgrades file contents.
I want to configure unattended-upgrades with the following string (from the Debian Wiki Unattended-upgrades page) :https://wiki.debian.org/UnattendedUpgrades
suggests to use this "Or non-interactively by running:
echo unattended-upgrades unattended-upgrades/enable_auto_updates boolean true | debconf-set-selections dpkg-reconfigure -f noninteractive unattended-upgrades
So, when I run my script containing this suggested string I am seeing this:
Unknown option: f
Usage: debconf-set-selections [-vcu] [file]
-v, --verbose verbose output
-c, --checkonly only check the input file format
-u, --unseen do not set the 'seen' flag when preseeding values
I am assuming that the error "f" mentioned is referencing the "-f" option within the Debian Wiki script string suggestion. When the script completes everything seems to be working as expected. 'Unattended-upgrades' has installed without user intervention.
Like everyone, when I create my various bash scripts my bash education is on going. So, being a newbie script writer my question is this, is there a better way to script this non-interaction install of unattended-upgrades than that suggested on the Debian wiki page? Should this "f" complaint concern me or should I just ignore the error?