I am getting "Illegal option -n" and "[[: not found" when running this sh script.
This script used to work error-free for a long time and then at some point started breaking when I've updated something on my Ubuntu 18.04.3 VPS.
read -p "Do you wish to enable SSL for this domain? [Y/n]" -n 1 -r
echo
if [[ $REPLY =~ ^[Nn]$ ]]
then
# something here
else
# something else here
fi
"Illegal option -n" is related to line #1
"[[: not found" part is related to line #3