UFW Enable requires y prompt, how to automate with Bash Script?
Solution 1:
How about:
$ echo "y" | sudo ufw enable
Solution 2:
You could use:
$ sudo ufw --force enable
Solution 3:
yes
allows you to answer all questions from a program with y
.
yes | sudo ufw enable