install-mattermost.sh: a minor fix in checking prerequisites.
This commit is contained in:
		| @@ -597,11 +597,11 @@ _failed=false | |||||||
| if [[ "${DB_TYPE}" = "mysql" ]]; then | if [[ "${DB_TYPE}" = "mysql" ]]; then | ||||||
|    echononl "Check if MySQL Database Service is installed.." |    echononl "Check if MySQL Database Service is installed.." | ||||||
|    if $(dpkg -s mysql-server > "$log_file" 2>&1) ; then |    if $(dpkg -s mysql-server > "$log_file" 2>&1) ; then | ||||||
|       mysql_server_installed=true |       database_service_installed=true | ||||||
|    else |    else | ||||||
|       mysql_server_installed=false |       database_service_installed=false | ||||||
|    fi |    fi | ||||||
|    if $mysql_server_installed ; then |    if $database_service_installed ; then | ||||||
|       echo -e "\033[85G[ \033[32mYES\033[m ]" |       echo -e "\033[85G[ \033[32mYES\033[m ]" | ||||||
|    else |    else | ||||||
|       echo -e "\033[85G[ \033[1;31mNOT installed\033[m ]" |       echo -e "\033[85G[ \033[1;31mNOT installed\033[m ]" | ||||||
| @@ -618,11 +618,11 @@ if [[ "${DB_TYPE}" = "mysql" ]]; then | |||||||
| else | else | ||||||
|    echononl "Check if PostgreSQL Database Service is installed.." |    echononl "Check if PostgreSQL Database Service is installed.." | ||||||
|    if $(dpkg -s postgresql > "$log_file" 2>&1) ; then |    if $(dpkg -s postgresql > "$log_file" 2>&1) ; then | ||||||
|       postgresql_server_installed=true |       database_service_installed=true | ||||||
|    else |    else | ||||||
|       postgresql_server_installed=false |       database_service_installed=false | ||||||
|    fi |    fi | ||||||
|    if $postgresql_server_installed ; then |    if $database_service_installed ; then | ||||||
|       echo -e "\033[85G[ \033[32mYES\033[m ]" |       echo -e "\033[85G[ \033[32mYES\033[m ]" | ||||||
|    else |    else | ||||||
|       echo -e "\033[85G[ \033[1;31mNOT installed\033[m ]" |       echo -e "\033[85G[ \033[1;31mNOT installed\033[m ]" | ||||||
| @@ -656,12 +656,12 @@ else | |||||||
|    echo -e "\033[85G[ \033[1;31mNOT present\033[m ]" |    echo -e "\033[85G[ \033[1;31mNOT present\033[m ]" | ||||||
| fi | fi | ||||||
|  |  | ||||||
| if ! $nginx_installed || ! $mysql_server_installed ; then | if ! $nginx_installed || ! $database_service_installed ; then | ||||||
|  |  | ||||||
|    if ! $cert_present ; then |    if ! $nginx_installed ; then | ||||||
|  |  | ||||||
|       fatal "Prerequisites are a correct installation of the NGINX Web Service as well |       fatal "Prerequisites are a correct installation of the NGINX Web Service as well | ||||||
|              as a correct installation of the MySQL database service. |              as a correct installation of the $DB_TYPE database service. | ||||||
|  |  | ||||||
|              It's also highly recommended to have a valid certificate for your |              It's also highly recommended to have a valid certificate for your | ||||||
|              FQHN Hostname '${FQHN_HOSTNAME}'." |              FQHN Hostname '${FQHN_HOSTNAME}'." | ||||||
| @@ -669,7 +669,7 @@ if ! $nginx_installed || ! $mysql_server_installed ; then | |||||||
|    else |    else | ||||||
|  |  | ||||||
|       fatal "Prerequisites are a correct installation of the NGINX Web Service as well |       fatal "Prerequisites are a correct installation of the NGINX Web Service as well | ||||||
|              as a correct installation of the MySQL database service." |              as a correct installation of the $DB_TYPE database service." | ||||||
|    fi |    fi | ||||||
|  |  | ||||||
| elif ! $cert_present ; then | elif ! $cert_present ; then | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user