From 7c05e56505e485d1a50d0759c57a8b5d3b61ef13 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 19 Dec 2018 09:05:19 +0100 Subject: Wizard: add RHEL-8-Beta with module only instructions --- wizard/index.php | 51 +++++++++++++++++++++++++++++++++++---------------- 1 file changed, 35 insertions(+), 16 deletions(-) diff --git a/wizard/index.php b/wizard/index.php index 1f0b26e4..0346c4e5 100644 --- a/wizard/index.php +++ b/wizard/index.php @@ -15,6 +15,7 @@ define('EL_DEV', 8); define('COUNTER', __DIR__ . "/counter.txt"); $osvers = [ + 'RHEL 8' => '7.2', 'RHEL 7' => '5.4', 'RHEL 6' => '5.3', 'CentOS 7' => '5.4', @@ -25,6 +26,7 @@ $osvers = [ 'Fedora 26' => '7.1', ]; $osmin = [ + 'RHEL 8' => '7.2', 'RHEL 7' => '5.4', 'RHEL 6' => '5.4', 'CentOS 7' => '5.4', @@ -35,6 +37,7 @@ $osmin = [ 'Fedora 26' => '5.6', ]; $osmax = [ + 'RHEL 8' => '7.3', 'RHEL 7' => '7.3', 'RHEL 6' => '7.3', 'CentOS 7' => '7.3', @@ -45,6 +48,7 @@ $osmax = [ 'Fedora 26' => '7.2', ]; $osname = [ + 'RHEL 8' => 'RHEL-8-Beta (Development version, not ready for production)', 'RHEL 7' => 'RHEL-7', 'RHEL 6' => 'RHEL-6 (maintained until March 2020)', 'CentOS 7' => 'CentOS 7', @@ -171,23 +175,30 @@ if ($php && $os) { } if ($php && $os && $type && !$err) { if ($dist == 'Fedora') { + $mod = ($ver >= 29); $yum = 'dnf'; printf("
  • Command to install the Remi repository configuration package:"); printf("
        $yum install http://rpms.remirepo.net/fedora/remi-release-%d.rpm
    ", $ver); printf("

  • "); } else { - $yum = 'yum'; - printf("
  • Command to install the EPEL repository configuration package:"); - printf("
        $yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-%d.noarch.rpm
    ", $ver); - printf("

  • Command to install the Remi repository configuration package:"); + $mod = ($ver >= 8); + if ($ver >= EL_DEV) { + $yum = 'dnf'; + printf("
  • EPEL repository is not yet available.

  • "); + } else { + $yum = 'yum'; + printf("
  • Command to install the EPEL repository configuration package:"); + printf("
        $yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-%d.noarch.rpm

  • ", $ver); + } + printf("
  • Command to install the Remi repository configuration package:"); printf("
        $yum install http://rpms.remirepo.net/enterprise/remi-release-%d.rpm
    ", $ver); printf("

  • "); printf("
  • Command to install the yum-utils package (for the yum-config-manager command):"); printf("
        $yum install yum-utils
    "); printf("

  • "); - if ($dist == 'RHEL') { + if ($dist == 'RHEL' && $ver < EL_DEV) { printf("
  • On RHEL you (probably) need to enable the optional channel for some dependencies.

  • "); printf("
  • Command to enable:"); if ($ver == 7) { @@ -225,19 +236,23 @@ if ($php && $os && $type && !$err) { printf("
        dnf config-manager --set-enabled remi

  • "); } - printf("
  • PHP version %s packages are available for %s in %s repository

  • ", $php, $os, $repo); - printf("
  • If the priorities plugin is enabled, ensure %s have higher priority (a lower value) than %s

  • ", $repo, ($dist == 'Fedora' ? 'fedora' : 'base and updates')); - - printf("
  • Command to enable the repository:"); + if ($dist == 'Fedora' || $yum == 'yum') { + printf("
  • PHP version %s packages are available for %s in %s repository

  • ", $php, $os, $repo); + printf("
  • Command to enable the repository:"); + } if ($dist == 'Fedora') { - printf("
        dnf config-manager --set-enabled %s
    ", $repo); - } else { - printf("
        yum-config-manager --enable %s
    ", $repo); + printf("
        dnf config-manager --set-enabled %s

  • ", $repo); + if ($mod) { + printf("
  • Alternatively, you may prefer to enable the module:"); + } + } else if ($yum == 'yum') { // EL-6, 7 + printf("
        yum-config-manager --enable %s

  • ", $repo); + printf("
  • If the priorities plugin is enabled, ensure %s have higher priority (a lower value) than %s

  • ", $repo, ($dist == 'Fedora' ? 'fedora' : 'base and updates')); + } else { // EL-8, module only + printf("
  • You have to enable the module stream for $php:"); } - printf("

  • "); - if ($dist == 'Fedora' && $ver >= 29) { - printf("
  • Alternatively, you may prefer to enable the module:"); + if ($mod) { printf("
        dnf module install remi-php:%s
    ", $php); printf("

  • "); } @@ -252,7 +267,11 @@ if ($php && $os && $type && !$err) { if (version_compare($php, '7.0', '>=')) { printf("
  • Command to install testing packages:"); - printf("
        $yum --enablerepo=%s-test install php-xxx
    ", $repo); + if ($dist != 'Fedora' && $mod) { + printf("
        $yum --enablerepo=remi-modular-test install php-xxx
    ", $repo); + } else { + printf("
        $yum --enablerepo=%s-test install php-xxx
    ", $repo); + } printf("

  • "); } -- cgit