Skip to content
Snippets Groups Projects
Select Git revision
  • ac98f61df06bdfdc7e5d3800ef5557a255cfe88f
  • master default protected
  • 288-php8-warnungen
  • vips-1.9 protected
  • issue-255
  • vips-1.8 protected
  • 1.9.9
  • 1.9.8
  • 1.9.7
  • 1.9.6
  • 1.9.5
  • 1.9.4
  • 1.9.3
  • 1.9.2
  • 1.9.1
  • 1.9
  • 1.8.8
  • 1.8.7
  • 1.8.6
  • 1.8.5
  • 1.8.4
  • 1.8.3
  • 1.8.2
  • 1.8.1
  • 1.8
25 results

vips.js

Blame
  • Code owners
    Assign users and groups as approvers for specific file changes. Learn more.
    SupportedPHPVersions.php 832 B
    <?php
    namespace Studip\Dockerized;
    
    final class SupportedPHPVersions
    {
        private const CONFIGURATION = [
            '7.2' => [8072, 8872],
            '7.3' => [8073, 8873],
            '7.4' => [8074, 8874],
            '8.0' => [8080, 8880],
            '8.1' => [8081, 8881],
            '8.2' => [8082, 8882],
            '8.3' => [8083, 8883],
        ];
    
        private const DEFAULT = ['7.4', '8.1', '8.3'];
    
        public static function getVersions(): array
        {
            return array_keys(self::CONFIGURATION);
        }
    
        public static function getDefaultVersions(): array
        {
            return self::DEFAULT;
        }
    
        public static function mapPort(string $version): int
        {
            if (!isset(self::CONFIGURATION[$version])) {
                throw new \Exception('Unsupported php version');
            }
            return self::CONFIGURATION[$version];
        }
    }