]> pere.pagekite.me Git - exim4-smtorp.git/commitdiff
Try to set up tor even if exim4 is already configured.
authorPetter Reinholdtsen <pere@hungry.com>
Sun, 9 Aug 2020 20:23:47 +0000 (22:23 +0200)
committerPetter Reinholdtsen <pere@hungry.com>
Sun, 9 Aug 2020 20:23:47 +0000 (22:23 +0200)
setup-exim-hidden-service

index 76c68c3b953a48f39494d820386d87a561c5cd70..d14a3ae5ddb0d00586d7a5de9b8e5183ee38a790 100644 (file)
@@ -3,15 +3,6 @@
 # Configure a machine without exim installed as a mail server receiving
 # email using SMTP via Tor.
 
-if dpkg -l exim4-config > /dev/null ; then
-    echo "******************************************************************"
-    echo "* Unable to set up SMTP over Tor, exim4-config already installed *"
-    echo "* Purge the package and try again, or                            *"
-    echo "* run "dpkg-reconfigure exim4-config" to configure manually.     *"
-    echo "******************************************************************"
-    exit 1
-fi
-
 append_if_missing() {
     file="$1"
     string="$2"
@@ -49,6 +40,16 @@ else
     fi
 fi
 
+if dpkg -l exim4-config > /dev/null ; then
+    echo "******************************************************************"
+    echo "* Unable to set up SMTP over Tor, exim4-config already installed *"
+    echo "* Purge the package and try again, or                            *"
+    echo "* run "dpkg-reconfigure exim4-config" to configure manually.     *"
+    echo "******************************************************************"
+    echo "* Enable '$torhsname' as mail domain.
+    exit 1
+fi
+
 cat <<EOF | debconf-set-selections
 exim4-config   exim4/dc_eximconfig_configtype  select  internet site; mail is sent and received directly using SMTP
 exim4-config   exim4/dc_local_interfaces       string  127.0.0.1 ; ::1