--- doc/install/linux/install.pl 2021/12/20 03:13:29 1.79 +++ doc/install/linux/install.pl 2021/12/21 13:57:46 1.80 @@ -78,7 +78,7 @@ if (!open(LOG,">>loncapa_install.log")) &mt('Stopping execution.')."\n"; exit; } else { - print LOG '$Id: install.pl,v 1.79 2021/12/20 03:13:29 raeburn Exp $'."\n"; + print LOG '$Id: install.pl,v 1.80 2021/12/21 13:57:46 raeburn Exp $'."\n"; } # @@ -212,8 +212,11 @@ sub get_distro { $distro = 'rhes'.$1; $updatecmd = 'dnf install LONCAPA-prerequisites'; $installnow = 'dnf -y install LONCAPA-prerequisites'; - } elsif ($versionstring =~ /CentOS(?:| Linux| Stream) release (\d+)/) { - $distro = 'centos'.$1; + } elsif ($versionstring =~ /CentOS(| Linux| Stream) release (\d+)/) { + $distro = 'centos'.$2; + if ($1 eq ' Stream') { + $distro .= '-stream'; + } $updatecmd = 'yum install LONCAPA-prerequisites'; $installnow = 'yum -y install LONCAPA-prerequisites'; } elsif ($versionstring =~ /Scientific Linux (?:SL )?release ([\d.]+) /) { @@ -2237,7 +2240,7 @@ if ($callsub{'firewall'}) { 'ssh, http')."\n"; } else { my $version; - if ($distro =~ /^(redhat|centos)(\d+)$/) { + if ($distro =~ /^(redhat|centos)(\d+)/) { $version = $1; } if ($version > 5) { @@ -2318,7 +2321,7 @@ if ($have_tarball && !$updateshown) { if ($1 > 6) { $lc_uses_systemctl = 1; } - } elsif ($distro =~ /^(?:rhes|centos|rocky|alma)(\d+)$/) { + } elsif ($distro =~ /^(?:rhes|centos|rocky|alma)(\d+)/) { if ($1 > 7) { $lc_uses_systemctl = 1; } @@ -2751,7 +2754,7 @@ sub get_mysql_version { sub copy_httpd_conf { my ($instdir,$distro,$hostname) = @_; my $configfile = 'httpd.conf'; - if ($distro =~ /^(?:centos|rhes|scientific|oracle|rocky|alma)(\d+)$/) { + if ($distro =~ /^(?:centos|rhes|scientific|oracle|rocky|alma)(\d+)/) { if ($1 >= 7) { $configfile = 'apache2.4/httpd.conf'; } elsif ($1 > 5) { @@ -2798,7 +2801,7 @@ sub copy_mpm_conf { print_and_log("\n"); } else { my $logfail; - if ($distro =~ /^(?:centos|rhes|scientific|oracle|rocky|alma)(\d+)$/) { + if ($distro =~ /^(?:centos|rhes|scientific|oracle|rocky|alma)(\d+)/) { if ($1 > 7) { $logfail = 1; }