pirogue-images/raspberrypi/files/avoid-debconf-prompts
Cyril Brulebois c1be115a2f Avoid 3 known debconf prompts during deployment.
Even if those prompts and the associated answers are already documented
in “Beginner guide - How to setup a PiRogue”, it's a bit annoying to
have to go through them every time a new PiRogue is set up.

Let's pick the right answers (moving away from the default every time),
and mark those questions as seen (i.e. asked and answered):

 - Save current IPv4 rules?                           Yes → No
 - Save current IPv6 rules?                           Yes → No
 - Should non-superusers be able to capture packets?  No → Yes

Link: https://github.com/PiRogueToolSuite/pirogue-images/issues/3
2024-07-28 21:28:10 +02:00

22 lines
882 B
Bash

#!/bin/sh
#
# A number of packages are going to ask questions via debconf prompts. Since we
# know which answers are the right ones, set the right values and mark those
# questions as seen, instead of having users follow documentation.
#
# See https://github.com/PiRogueToolSuite/pirogue-images/issues/3
#
# Reminder: debconf-set-selections comes with debconf, debconf-get-selections is
# shipped in the debconf-utils package (not installed by default).
set -e
cat <<EOF | debconf-set-selections -v
iptables-persistent iptables-persistent/autosave_v4 boolean false
iptables-persistent iptables-persistent/autosave_v4 seen true
iptables-persistent iptables-persistent/autosave_v6 boolean false
iptables-persistent iptables-persistent/autosave_v6 seen true
wireshark-common wireshark-common/install-setuid boolean true
wireshark-common wireshark-common/install-setuid seen true
EOF