mailwatch / mailwatch-install-script

Install script for automated MailWatch install
5 stars 5 forks source link

Nginx option on debian 9 installs Apache2 #25

Open endelwar opened 7 years ago

endelwar commented 7 years ago

I'm installing on a test VM with minimal Debian 9 installed; after selecting Nginx as webserver option apache2 is in the list of packages to be installed

We're unable to find your webserver.  We support Apache and Nginx

Do you wish to install a webserver?
1 - Apache
2 - Nginx
n - do not install or configure

Select Webserver: 2
Installing nginx
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  fontconfig-config fonts-dejavu-core geoip-database libfontconfig1 libgd3 libgeoip1 libjbig0 libjpeg62-turbo libnginx-mod-http-auth-pam libnginx-mod-http-dav-ext
  libnginx-mod-http-echo libnginx-mod-http-geoip libnginx-mod-http-image-filter libnginx-mod-http-subs-filter libnginx-mod-http-upstream-fair
  libnginx-mod-http-xslt-filter libnginx-mod-mail libnginx-mod-stream libtiff5 libwebp6 libxpm4 libxslt1.1 nginx-common nginx-full
Suggested packages:
  libgd-tools geoip-bin fcgiwrap nginx-doc
The following NEW packages will be installed:
  fontconfig-config fonts-dejavu-core geoip-database libfontconfig1 libgd3 libgeoip1 libjbig0 libjpeg62-turbo libnginx-mod-http-auth-pam libnginx-mod-http-dav-ext
  libnginx-mod-http-echo libnginx-mod-http-geoip libnginx-mod-http-image-filter libnginx-mod-http-subs-filter libnginx-mod-http-upstream-fair
  libnginx-mod-http-xslt-filter libnginx-mod-mail libnginx-mod-stream libtiff5 libwebp6 libxpm4 libxslt1.1 nginx nginx-common nginx-full
0 upgraded, 25 newly installed, 0 to remove and 0 not upgraded.
Need to get 6,507 kB of archives.
After this operation, 16.8 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://ftp.it.debian.org/debian stretch/main amd64 fonts-dejavu-core all 2.37-1 [1,068 kB]
Get:2 http://security.debian.org/debian-security stretch/updates/main amd64 libtiff5 amd64 4.0.8-2+deb9u1 [237 kB]
Get:3 http://security.debian.org/debian-security stretch/updates/main amd64 nginx-common all 1.10.3-1+deb9u1 [104 kB]
Get:4 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-auth-pam amd64 1.10.3-1+deb9u1 [85.8 kB]
Get:5 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-dav-ext amd64 1.10.3-1+deb9u1 [87.5 kB]
Get:6 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-echo amd64 1.10.3-1+deb9u1 [96.9 kB]
Get:7 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-geoip amd64 1.10.3-1+deb9u1 [87.0 kB]
Get:8 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-image-filter amd64 1.10.3-1+deb9u1 [89.9 kB]
Get:9 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-subs-filter amd64 1.10.3-1+deb9u1 [88.8 kB]
Get:10 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-upstream-fair amd64 1.10.3-1+deb9u1 [89.0 kB]
Get:11 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-http-xslt-filter amd64 1.10.3-1+deb9u1 [88.8 kB]
Get:12 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-mail amd64 1.10.3-1+deb9u1 [117 kB]
Get:13 http://security.debian.org/debian-security stretch/updates/main amd64 libnginx-mod-stream amd64 1.10.3-1+deb9u1 [110 kB]
Get:14 http://ftp.it.debian.org/debian stretch/main amd64 fontconfig-config all 2.11.0-6.7 [271 kB]
Get:15 http://ftp.it.debian.org/debian stretch/main amd64 geoip-database all 20170512-1 [2,112 kB]
Get:16 http://security.debian.org/debian-security stretch/updates/main amd64 nginx-full amd64 1.10.3-1+deb9u1 [458 kB]
Get:17 http://security.debian.org/debian-security stretch/updates/main amd64 nginx all 1.10.3-1+deb9u1 [81.5 kB]
Get:18 http://ftp.it.debian.org/debian stretch/main amd64 libfontconfig1 amd64 2.11.0-6.7+b1 [331 kB]
Get:19 http://ftp.it.debian.org/debian stretch/main amd64 libjpeg62-turbo amd64 1:1.5.1-2 [134 kB]
Get:20 http://ftp.it.debian.org/debian stretch/main amd64 libjbig0 amd64 2.1-3.1+b2 [31.0 kB]
Get:21 http://ftp.it.debian.org/debian stretch/main amd64 libwebp6 amd64 0.5.2-1 [235 kB]
Get:22 http://ftp.it.debian.org/debian stretch/main amd64 libxpm4 amd64 1:3.5.12-1 [49.1 kB]
Get:23 http://ftp.it.debian.org/debian stretch/main amd64 libgd3 amd64 2.2.4-2 [132 kB]
Get:24 http://ftp.it.debian.org/debian stretch/main amd64 libgeoip1 amd64 1.6.9-4 [90.5 kB]
Get:25 http://ftp.it.debian.org/debian stretch/main amd64 libxslt1.1 amd64 1.1.29-2.1 [233 kB]
Fetched 6,507 kB in 1s (3,987 kB/s)
Preconfiguring packages ...
Selecting previously unselected package fonts-dejavu-core.
(Reading database ... 34151 files and directories currently installed.)
Preparing to unpack .../00-fonts-dejavu-core_2.37-1_all.deb ...
Unpacking fonts-dejavu-core (2.37-1) ...
Selecting previously unselected package fontconfig-config.
Preparing to unpack .../01-fontconfig-config_2.11.0-6.7_all.deb ...
Unpacking fontconfig-config (2.11.0-6.7) ...
Selecting previously unselected package geoip-database.
Preparing to unpack .../02-geoip-database_20170512-1_all.deb ...
Unpacking geoip-database (20170512-1) ...
Selecting previously unselected package libfontconfig1:amd64.
Preparing to unpack .../03-libfontconfig1_2.11.0-6.7+b1_amd64.deb ...
Unpacking libfontconfig1:amd64 (2.11.0-6.7+b1) ...
Selecting previously unselected package libjpeg62-turbo:amd64.
Preparing to unpack .../04-libjpeg62-turbo_1%3a1.5.1-2_amd64.deb ...
Unpacking libjpeg62-turbo:amd64 (1:1.5.1-2) ...
Selecting previously unselected package libjbig0:amd64.
Preparing to unpack .../05-libjbig0_2.1-3.1+b2_amd64.deb ...
Unpacking libjbig0:amd64 (2.1-3.1+b2) ...
Selecting previously unselected package libtiff5:amd64.
Preparing to unpack .../06-libtiff5_4.0.8-2+deb9u1_amd64.deb ...
Unpacking libtiff5:amd64 (4.0.8-2+deb9u1) ...
Selecting previously unselected package libwebp6:amd64.
Preparing to unpack .../07-libwebp6_0.5.2-1_amd64.deb ...
Unpacking libwebp6:amd64 (0.5.2-1) ...
Selecting previously unselected package libxpm4:amd64.
Preparing to unpack .../08-libxpm4_1%3a3.5.12-1_amd64.deb ...
Unpacking libxpm4:amd64 (1:3.5.12-1) ...
Selecting previously unselected package libgd3:amd64.
Preparing to unpack .../09-libgd3_2.2.4-2_amd64.deb ...
Unpacking libgd3:amd64 (2.2.4-2) ...
Selecting previously unselected package libgeoip1:amd64.
Preparing to unpack .../10-libgeoip1_1.6.9-4_amd64.deb ...
Unpacking libgeoip1:amd64 (1.6.9-4) ...
Selecting previously unselected package nginx-common.
Preparing to unpack .../11-nginx-common_1.10.3-1+deb9u1_all.deb ...
Unpacking nginx-common (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-http-auth-pam.
Preparing to unpack .../12-libnginx-mod-http-auth-pam_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-auth-pam (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-http-dav-ext.
Preparing to unpack .../13-libnginx-mod-http-dav-ext_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-dav-ext (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-http-echo.
Preparing to unpack .../14-libnginx-mod-http-echo_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-echo (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-http-geoip.
Preparing to unpack .../15-libnginx-mod-http-geoip_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-geoip (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-http-image-filter.
Preparing to unpack .../16-libnginx-mod-http-image-filter_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-image-filter (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-http-subs-filter.
Preparing to unpack .../17-libnginx-mod-http-subs-filter_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-subs-filter (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-http-upstream-fair.
Preparing to unpack .../18-libnginx-mod-http-upstream-fair_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-upstream-fair (1.10.3-1+deb9u1) ...
Selecting previously unselected package libxslt1.1:amd64.
Preparing to unpack .../19-libxslt1.1_1.1.29-2.1_amd64.deb ...
Unpacking libxslt1.1:amd64 (1.1.29-2.1) ...
Selecting previously unselected package libnginx-mod-http-xslt-filter.
Preparing to unpack .../20-libnginx-mod-http-xslt-filter_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-http-xslt-filter (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-mail.
Preparing to unpack .../21-libnginx-mod-mail_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-mail (1.10.3-1+deb9u1) ...
Selecting previously unselected package libnginx-mod-stream.
Preparing to unpack .../22-libnginx-mod-stream_1.10.3-1+deb9u1_amd64.deb ...
Unpacking libnginx-mod-stream (1.10.3-1+deb9u1) ...
Selecting previously unselected package nginx-full.
Preparing to unpack .../23-nginx-full_1.10.3-1+deb9u1_amd64.deb ...
Unpacking nginx-full (1.10.3-1+deb9u1) ...
Selecting previously unselected package nginx.
Preparing to unpack .../24-nginx_1.10.3-1+deb9u1_all.deb ...
Unpacking nginx (1.10.3-1+deb9u1) ...
Setting up libjpeg62-turbo:amd64 (1:1.5.1-2) ...
Setting up geoip-database (20170512-1) ...
Setting up libjbig0:amd64 (2.1-3.1+b2) ...
Setting up fonts-dejavu-core (2.37-1) ...
Setting up nginx-common (1.10.3-1+deb9u1) ...
Created symlink /etc/systemd/system/multi-user.target.wants/nginx.service → /lib/systemd/system/nginx.service.
Setting up libnginx-mod-http-subs-filter (1.10.3-1+deb9u1) ...
Setting up libtiff5:amd64 (4.0.8-2+deb9u1) ...
Processing triggers for sgml-base (1.29) ...
Setting up libgeoip1:amd64 (1.6.9-4) ...
Setting up libxslt1.1:amd64 (1.1.29-2.1) ...
Processing triggers for libc-bin (2.24-11+deb9u1) ...
Processing triggers for systemd (232-25) ...
Setting up libnginx-mod-http-auth-pam (1.10.3-1+deb9u1) ...
Setting up libnginx-mod-http-dav-ext (1.10.3-1+deb9u1) ...
Setting up libnginx-mod-mail (1.10.3-1+deb9u1) ...
Setting up libxpm4:amd64 (1:3.5.12-1) ...
Setting up libnginx-mod-http-xslt-filter (1.10.3-1+deb9u1) ...
Setting up libnginx-mod-http-upstream-fair (1.10.3-1+deb9u1) ...
Setting up libnginx-mod-http-geoip (1.10.3-1+deb9u1) ...
Setting up libwebp6:amd64 (0.5.2-1) ...
Setting up fontconfig-config (2.11.0-6.7) ...
Setting up libnginx-mod-stream (1.10.3-1+deb9u1) ...
Setting up libnginx-mod-http-echo (1.10.3-1+deb9u1) ...
Setting up libfontconfig1:amd64 (2.11.0-6.7+b1) ...
Setting up libgd3:amd64 (2.2.4-2) ...
Setting up libnginx-mod-http-image-filter (1.10.3-1+deb9u1) ...
Setting up nginx-full (1.10.3-1+deb9u1) ...
Setting up nginx (1.10.3-1+deb9u1) ...
Processing triggers for libc-bin (2.24-11+deb9u1) ...

MailWatch requires the php packages php php-gd and php-mysqlnd. Do you want to install them if missing?(y/n)[y]: y
Installing required php packages
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  apache2 apache2-bin apache2-data apache2-utils libapache2-mod-php7.0 libapr1 libaprutil1 libaprutil1-dbd-sqlite3 libaprutil1-ldap liblua5.2-0 php-common php7.0
  php7.0-cli php7.0-common php7.0-curl php7.0-gd php7.0-json php7.0-mbstring php7.0-mysql php7.0-opcache php7.0-readline
Suggested packages:
  www-browser apache2-doc apache2-suexec-pristine | apache2-suexec-custom php-pear
The following NEW packages will be installed:
  apache2 apache2-bin apache2-data apache2-utils libapache2-mod-php7.0 libapr1 libaprutil1 libaprutil1-dbd-sqlite3 libaprutil1-ldap liblua5.2-0 php php-common php-curl
  php-gd php-mbstring php-mysql php7.0 php7.0-cli php7.0-common php7.0-curl php7.0-gd php7.0-json php7.0-mbstring php7.0-mysql php7.0-opcache php7.0-readline
0 upgraded, 26 newly installed, 0 to remove and 0 not upgraded.
Need to get 6,349 kB of archives.
After this operation, 23.5 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://security.debian.org/debian-security stretch/updates/main amd64 apache2-bin amd64 2.4.25-3+deb9u1 [1,181 kB]
Get:2 http://ftp.it.debian.org/debian stretch/main amd64 libapr1 amd64 1.5.2-5 [96.6 kB]
Get:3 http://ftp.it.debian.org/debian stretch/main amd64 libaprutil1 amd64 1.5.4-3 [85.8 kB]
Get:4 http://ftp.it.debian.org/debian stretch/main amd64 libaprutil1-dbd-sqlite3 amd64 1.5.4-3 [19.3 kB]
Get:5 http://ftp.it.debian.org/debian stretch/main amd64 libaprutil1-ldap amd64 1.5.4-3 [17.4 kB]
Get:6 http://ftp.it.debian.org/debian stretch/main amd64 liblua5.2-0 amd64 5.2.4-1.1+b2 [110 kB]
Get:7 http://ftp.it.debian.org/debian stretch/main amd64 php-common all 1:49 [14.1 kB]
Get:8 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-common amd64 7.0.19-1 [868 kB]
Get:9 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-json amd64 7.0.19-1 [17.1 kB]
Get:10 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-opcache amd64 7.0.19-1 [77.2 kB]
Get:11 http://security.debian.org/debian-security stretch/updates/main amd64 apache2-utils amd64 2.4.25-3+deb9u1 [217 kB]
Get:12 http://security.debian.org/debian-security stretch/updates/main amd64 apache2-data all 2.4.25-3+deb9u1 [162 kB]
Get:13 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-readline amd64 7.0.19-1 [12.2 kB]
Get:14 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-cli amd64 7.0.19-1 [1,289 kB]
Get:15 http://security.debian.org/debian-security stretch/updates/main amd64 apache2 amd64 2.4.25-3+deb9u1 [235 kB]
Get:16 http://ftp.it.debian.org/debian stretch/main amd64 libapache2-mod-php7.0 amd64 7.0.19-1 [1,231 kB]
Get:17 http://ftp.it.debian.org/debian stretch/main amd64 php7.0 all 7.0.19-1 [48.7 kB]
Get:18 http://ftp.it.debian.org/debian stretch/main amd64 php all 1:7.0+49 [5,016 B]
Get:19 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-curl amd64 7.0.19-1 [27.3 kB]
Get:20 http://ftp.it.debian.org/debian stretch/main amd64 php-curl all 1:7.0+49 [5,048 B]
Get:21 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-gd amd64 7.0.19-1 [27.0 kB]
Get:22 http://ftp.it.debian.org/debian stretch/main amd64 php-gd all 1:7.0+49 [5,042 B]
Get:23 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-mbstring amd64 7.0.19-1 [465 kB]
Get:24 http://ftp.it.debian.org/debian stretch/main amd64 php-mbstring all 1:7.0+49 [5,058 B]
Get:25 http://ftp.it.debian.org/debian stretch/main amd64 php7.0-mysql amd64 7.0.19-1 [124 kB]
Get:26 http://ftp.it.debian.org/debian stretch/main amd64 php-mysql all 1:7.0+49 [5,052 B]
Fetched 6,349 kB in 1s (4,706 kB/s)
Selecting previously unselected package libapr1:amd64.
(Reading database ... 34458 files and directories currently installed.)
Preparing to unpack .../00-libapr1_1.5.2-5_amd64.deb ...
Unpacking libapr1:amd64 (1.5.2-5) ...
Selecting previously unselected package libaprutil1:amd64.
Preparing to unpack .../01-libaprutil1_1.5.4-3_amd64.deb ...
Unpacking libaprutil1:amd64 (1.5.4-3) ...
Selecting previously unselected package libaprutil1-dbd-sqlite3:amd64.
Preparing to unpack .../02-libaprutil1-dbd-sqlite3_1.5.4-3_amd64.deb ...
Unpacking libaprutil1-dbd-sqlite3:amd64 (1.5.4-3) ...
Selecting previously unselected package libaprutil1-ldap:amd64.
Preparing to unpack .../03-libaprutil1-ldap_1.5.4-3_amd64.deb ...
Unpacking libaprutil1-ldap:amd64 (1.5.4-3) ...
Selecting previously unselected package liblua5.2-0:amd64.
Preparing to unpack .../04-liblua5.2-0_5.2.4-1.1+b2_amd64.deb ...
Unpacking liblua5.2-0:amd64 (5.2.4-1.1+b2) ...
Selecting previously unselected package apache2-bin.
Preparing to unpack .../05-apache2-bin_2.4.25-3+deb9u1_amd64.deb ...
Unpacking apache2-bin (2.4.25-3+deb9u1) ...
Selecting previously unselected package apache2-utils.
Preparing to unpack .../06-apache2-utils_2.4.25-3+deb9u1_amd64.deb ...
Unpacking apache2-utils (2.4.25-3+deb9u1) ...
Selecting previously unselected package apache2-data.
Preparing to unpack .../07-apache2-data_2.4.25-3+deb9u1_all.deb ...
Unpacking apache2-data (2.4.25-3+deb9u1) ...
Selecting previously unselected package apache2.
Preparing to unpack .../08-apache2_2.4.25-3+deb9u1_amd64.deb ...
Unpacking apache2 (2.4.25-3+deb9u1) ...
Selecting previously unselected package php-common.
Preparing to unpack .../09-php-common_1%3a49_all.deb ...
Unpacking php-common (1:49) ...
Selecting previously unselected package php7.0-common.
Preparing to unpack .../10-php7.0-common_7.0.19-1_amd64.deb ...
Unpacking php7.0-common (7.0.19-1) ...
Selecting previously unselected package php7.0-json.
Preparing to unpack .../11-php7.0-json_7.0.19-1_amd64.deb ...
Unpacking php7.0-json (7.0.19-1) ...
Selecting previously unselected package php7.0-opcache.
Preparing to unpack .../12-php7.0-opcache_7.0.19-1_amd64.deb ...
Unpacking php7.0-opcache (7.0.19-1) ...
Selecting previously unselected package php7.0-readline.
Preparing to unpack .../13-php7.0-readline_7.0.19-1_amd64.deb ...
Unpacking php7.0-readline (7.0.19-1) ...
Selecting previously unselected package php7.0-cli.
Preparing to unpack .../14-php7.0-cli_7.0.19-1_amd64.deb ...
Unpacking php7.0-cli (7.0.19-1) ...
Selecting previously unselected package libapache2-mod-php7.0.
Preparing to unpack .../15-libapache2-mod-php7.0_7.0.19-1_amd64.deb ...
Unpacking libapache2-mod-php7.0 (7.0.19-1) ...
Selecting previously unselected package php7.0.
Preparing to unpack .../16-php7.0_7.0.19-1_all.deb ...
Unpacking php7.0 (7.0.19-1) ...
Selecting previously unselected package php.
Preparing to unpack .../17-php_1%3a7.0+49_all.deb ...
Unpacking php (1:7.0+49) ...
Selecting previously unselected package php7.0-curl.
Preparing to unpack .../18-php7.0-curl_7.0.19-1_amd64.deb ...
Unpacking php7.0-curl (7.0.19-1) ...
Selecting previously unselected package php-curl.
Preparing to unpack .../19-php-curl_1%3a7.0+49_all.deb ...
Unpacking php-curl (1:7.0+49) ...
Selecting previously unselected package php7.0-gd.
Preparing to unpack .../20-php7.0-gd_7.0.19-1_amd64.deb ...
Unpacking php7.0-gd (7.0.19-1) ...
Selecting previously unselected package php-gd.
Preparing to unpack .../21-php-gd_1%3a7.0+49_all.deb ...
Unpacking php-gd (1:7.0+49) ...
Selecting previously unselected package php7.0-mbstring.
Preparing to unpack .../22-php7.0-mbstring_7.0.19-1_amd64.deb ...
Unpacking php7.0-mbstring (7.0.19-1) ...
Selecting previously unselected package php-mbstring.
Preparing to unpack .../23-php-mbstring_1%3a7.0+49_all.deb ...
Unpacking php-mbstring (1:7.0+49) ...
Selecting previously unselected package php7.0-mysql.
Preparing to unpack .../24-php7.0-mysql_7.0.19-1_amd64.deb ...
Unpacking php7.0-mysql (7.0.19-1) ...
Selecting previously unselected package php-mysql.
Preparing to unpack .../25-php-mysql_1%3a7.0+49_all.deb ...
Unpacking php-mysql (1:7.0+49) ...
Setting up libapr1:amd64 (1.5.2-5) ...
Setting up apache2-data (2.4.25-3+deb9u1) ...
Processing triggers for libc-bin (2.24-11+deb9u1) ...
Setting up libaprutil1:amd64 (1.5.4-3) ...
Setting up php-common (1:49) ...
Created symlink /etc/systemd/system/timers.target.wants/phpsessionclean.timer → /lib/systemd/system/phpsessionclean.timer.
Processing triggers for systemd (232-25) ...
Setting up liblua5.2-0:amd64 (5.2.4-1.1+b2) ...
Setting up php7.0-common (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/calendar.ini with new version

Creating config file /etc/php/7.0/mods-available/ctype.ini with new version

Creating config file /etc/php/7.0/mods-available/exif.ini with new version

Creating config file /etc/php/7.0/mods-available/fileinfo.ini with new version

Creating config file /etc/php/7.0/mods-available/ftp.ini with new version

Creating config file /etc/php/7.0/mods-available/gettext.ini with new version

Creating config file /etc/php/7.0/mods-available/iconv.ini with new version

Creating config file /etc/php/7.0/mods-available/pdo.ini with new version

Creating config file /etc/php/7.0/mods-available/phar.ini with new version

Creating config file /etc/php/7.0/mods-available/posix.ini with new version

Creating config file /etc/php/7.0/mods-available/shmop.ini with new version

Creating config file /etc/php/7.0/mods-available/sockets.ini with new version

Creating config file /etc/php/7.0/mods-available/sysvmsg.ini with new version

Creating config file /etc/php/7.0/mods-available/sysvsem.ini with new version

Creating config file /etc/php/7.0/mods-available/sysvshm.ini with new version

Creating config file /etc/php/7.0/mods-available/tokenizer.ini with new version
Setting up libaprutil1-ldap:amd64 (1.5.4-3) ...
Setting up php7.0-mysql (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/mysqlnd.ini with new version

Creating config file /etc/php/7.0/mods-available/mysqli.ini with new version

Creating config file /etc/php/7.0/mods-available/pdo_mysql.ini with new version
Setting up php7.0-readline (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/readline.ini with new version
Setting up php7.0-opcache (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/opcache.ini with new version
Setting up php7.0-mbstring (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/mbstring.ini with new version
Setting up libaprutil1-dbd-sqlite3:amd64 (1.5.4-3) ...
Setting up apache2-utils (2.4.25-3+deb9u1) ...
Setting up apache2-bin (2.4.25-3+deb9u1) ...
Setting up php7.0-gd (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/gd.ini with new version
Setting up php7.0-curl (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/curl.ini with new version
Setting up php-mbstring (1:7.0+49) ...
Setting up php7.0-json (7.0.19-1) ...

Creating config file /etc/php/7.0/mods-available/json.ini with new version
Setting up php-gd (1:7.0+49) ...
Setting up php-mysql (1:7.0+49) ...
Setting up apache2 (2.4.25-3+deb9u1) ...
Enabling module mpm_event.
Enabling module authz_core.
Enabling module authz_host.
Enabling module authn_core.
Enabling module auth_basic.
Enabling module access_compat.
Enabling module authn_file.
Enabling module authz_user.
Enabling module alias.
Enabling module dir.
Enabling module autoindex.
Enabling module env.
Enabling module mime.
Enabling module negotiation.
Enabling module setenvif.
Enabling module filter.
Enabling module deflate.
Enabling module status.
Enabling module reqtimeout.
Enabling conf charset.
Enabling conf localized-error-pages.
Enabling conf other-vhosts-access-log.
Enabling conf security.
Enabling conf serve-cgi-bin.
Enabling site 000-default.
Created symlink /etc/systemd/system/multi-user.target.wants/apache2.service → /lib/systemd/system/apache2.service.
Created symlink /etc/systemd/system/multi-user.target.wants/apache-htcacheclean.service → /lib/systemd/system/apache-htcacheclean.service.
Job for apache2.service failed because the control process exited with error code.
See "systemctl status apache2.service" and "journalctl -xe" for details.
invoke-rc.d: initscript apache2, action "start" failed.
● apache2.service - The Apache HTTP Server
   Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Thu 2017-07-13 13:13:36 CEST; 5ms ago
  Process: 26352 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)

Jul 13 13:13:36 debian9 apachectl[26352]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
Jul 13 13:13:36 debian9 apachectl[26352]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80
Jul 13 13:13:36 debian9 apachectl[26352]: no listening sockets available, shutting down
Jul 13 13:13:36 debian9 apachectl[26352]: AH00015: Unable to open logs
Jul 13 13:13:36 debian9 apachectl[26352]: Action 'start' failed.
Jul 13 13:13:36 debian9 apachectl[26352]: The Apache error log may have more information.
Jul 13 13:13:36 debian9 systemd[1]: apache2.service: Control process exited, code=exited status=1
Jul 13 13:13:36 debian9 systemd[1]: Failed to start The Apache HTTP Server.
Jul 13 13:13:36 debian9 systemd[1]: apache2.service: Unit entered failed state.
Jul 13 13:13:36 debian9 systemd[1]: apache2.service: Failed with result 'exit-code'.
Setting up php-curl (1:7.0+49) ...
Setting up php7.0-cli (7.0.19-1) ...
update-alternatives: using /usr/bin/php7.0 to provide /usr/bin/php (php) in auto mode
update-alternatives: using /usr/bin/phar7.0 to provide /usr/bin/phar (phar) in auto mode
update-alternatives: using /usr/bin/phar.phar7.0 to provide /usr/bin/phar.phar (phar.phar) in auto mode

Creating config file /etc/php/7.0/cli/php.ini with new version
Setting up libapache2-mod-php7.0 (7.0.19-1) ...

Creating config file /etc/php/7.0/apache2/php.ini with new version
Module mpm_event disabled.
Enabling module mpm_prefork.
apache2_switch_mpm Switch to prefork
Job for apache2.service failed because the control process exited with error code.
See "systemctl status apache2.service" and "journalctl -xe" for details.
invoke-rc.d: initscript apache2, action "restart" failed.
● apache2.service - The Apache HTTP Server
   Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Thu 2017-07-13 13:13:37 CEST; 4ms ago
  Process: 28273 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)

Jul 13 13:13:37 debian9 apachectl[28273]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
Jul 13 13:13:37 debian9 apachectl[28273]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80
Jul 13 13:13:37 debian9 apachectl[28273]: no listening sockets available, shutting down
Jul 13 13:13:37 debian9 apachectl[28273]: AH00015: Unable to open logs
Jul 13 13:13:37 debian9 apachectl[28273]: Action 'start' failed.
Jul 13 13:13:37 debian9 apachectl[28273]: The Apache error log may have more information.
Jul 13 13:13:37 debian9 systemd[1]: apache2.service: Control process exited, code=exited status=1
Jul 13 13:13:37 debian9 systemd[1]: Failed to start The Apache HTTP Server.
Jul 13 13:13:37 debian9 systemd[1]: apache2.service: Unit entered failed state.
Jul 13 13:13:37 debian9 systemd[1]: apache2.service: Failed with result 'exit-code'.
apache2_invoke: Enable module php7.0
Job for apache2.service failed because the control process exited with error code.
See "systemctl status apache2.service" and "journalctl -xe" for details.
invoke-rc.d: initscript apache2, action "restart" failed.
● apache2.service - The Apache HTTP Server
   Loaded: loaded (/lib/systemd/system/apache2.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Thu 2017-07-13 13:13:38 CEST; 6ms ago
  Process: 28323 ExecStart=/usr/sbin/apachectl start (code=exited, status=1/FAILURE)

Jul 13 13:13:38 debian9 apachectl[28323]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
Jul 13 13:13:38 debian9 apachectl[28323]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80
Jul 13 13:13:38 debian9 apachectl[28323]: no listening sockets available, shutting down
Jul 13 13:13:38 debian9 apachectl[28323]: AH00015: Unable to open logs
Jul 13 13:13:38 debian9 apachectl[28323]: Action 'start' failed.
Jul 13 13:13:38 debian9 apachectl[28323]: The Apache error log may have more information.
Jul 13 13:13:38 debian9 systemd[1]: apache2.service: Control process exited, code=exited status=1
Jul 13 13:13:38 debian9 systemd[1]: Failed to start The Apache HTTP Server.
Jul 13 13:13:38 debian9 systemd[1]: apache2.service: Unit entered failed state.
Jul 13 13:13:38 debian9 systemd[1]: apache2.service: Failed with result 'exit-code'.
Setting up php7.0 (7.0.19-1) ...
Setting up php (1:7.0+49) ...
Processing triggers for libc-bin (2.24-11+deb9u1) ...
Processing triggers for systemd (232-25) ...
Skywalker-11 commented 7 years ago

Found the problem: PHP7.0 has libapache2-mod-php7.0 as dependency if php7.0-fpm and php7.0-cgi are not beeing installed: https://packages.debian.org/stretch/php7.0

Skywalker-11 commented 7 years ago

Can you try #26? It should fix the problem. Nevertheless until now I have't tested nginx installation at all 😄

endelwar commented 7 years ago

Going to test in a couple of hours, also I'm going to prepare a basic nginx config file.

Should we continue with "/mailscanner" dir alias or move to the more modern "mailwatch.example.com" virtual domain in install script?

endelwar commented 7 years ago

I finally managed to test #26 and I can confirm that it works on debian 9 and debian 8.

I'm trying to create a base nginx config file, but nginx doesn't have a global alias like apache (Alias /mailwatch/ "WEBFOLDER"), aliases must reside inside a location directive, which must reside inside a server directive: in nginx every site definition is equivalent to a virtualhost, even the default catchall site (server_name _;).

I can take 2 way:

Should we sync this between nginx and apache?

Skywalker-11 commented 7 years ago

Im that case it is probably better to just use a virtualhost for both apache and nginx.