Skip to content

Commit

Permalink
Only allow Debian 12 installs as Ubuntu 24.04 has a bug with php mail…
Browse files Browse the repository at this point in the history
…-parse and ubuntu 22.04 PHP is too old and needs to be php 8.2 or above, also added cron to the install incase its not included removed unused print final screen
  • Loading branch information
Johnnyq committed Jun 25, 2024
1 parent 101b89d commit 8b3c4e3
Showing 1 changed file with 4 additions and 12 deletions.
16 changes: 4 additions & 12 deletions itflow_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,16 @@ check_root() {

# Check OS
check_os() {
if ! grep -E "22.04|24.04|12" "/etc/"*"release" &>/dev/null; then
echo -e "${RED}Error: This script only supports Ubuntu 22.04, Ubuntu 24.04 or Debian 12.${NC}"
if ! grep -E "12" "/etc/"*"release" &>/dev/null; then
echo -e "${RED}Error: This script only supports Debian 12 at the moment, ubuntu 24.04 has a bug with mail-parse.${NC}"
exit 1
fi
}

# Set Correct Timezone
set_timezone() {
dpkg-reconfigure tzdata
clear
}

# Get domain name from user
Expand All @@ -45,7 +46,7 @@ install_packages() {
apt-get install -y apache2 mariadb-server \
php libapache2-mod-php php-intl php-mysqli php-gd \
php-curl php-imap php-mailparse libapache2-mod-md \
certbot python3-certbot-apache git sudo whois
certbot python3-certbot-apache git sudo whois cron

mariadb_secure_installation

Expand Down Expand Up @@ -112,15 +113,6 @@ setup_mysql() {
mysql -e "FLUSH PRIVILEGES;"
}

print_final_instructions() {
echo "Please go to https://${domain} to finish setting up ITFlow"
echo ""
echo "In database setup section enter the following:"
echo "Database User: itflow"
echo "Database Name: itflow"
echo "Database Password: ${mariadbpwd}"
}

# Welcome Message
clear
echo "#############################################"
Expand Down

0 comments on commit 8b3c4e3

Please sign in to comment.