aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfilip <filip.komar@gmail.com>2023-02-26 21:51:52 +0100
committerfilip <filip.komar@gmail.com>2023-02-26 21:51:52 +0100
commit909578c5bfcbedd5eac918b89532639ce59846e0 (patch)
treedef6c3ecedec7b0ab2e88dffc3e1238f88ebed03
parente1a35ee59caab43ef38c9a5cc6e91ed84d279da8 (diff)
downloadwww-909578c5bfcbedd5eac918b89532639ce59846e0.tar
www-909578c5bfcbedd5eac918b89532639ce59846e0.tar.gz
www-909578c5bfcbedd5eac918b89532639ce59846e0.tar.bz2
www-909578c5bfcbedd5eac918b89532639ce59846e0.tar.xz
www-909578c5bfcbedd5eac918b89532639ce59846e0.zip
add config variables for cauldron releases
-rw-r--r--lib/Downloads.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Downloads.php b/lib/Downloads.php
index bcc02ecf2..b0c0c8330 100644
--- a/lib/Downloads.php
+++ b/lib/Downloads.php
@@ -155,7 +155,7 @@ class Downloads
require $cache_file;
} else {
- $data = file('http://mirrors.mageia.org/api/mageia.8.i586.list');
+ $data = file('http://mirrors.mageia.org/api/mageia.9.i586.list');
$mirrors = array();
$num_up = 0;
$num_dn = 0;
@@ -171,6 +171,7 @@ class Downloads
$num_of_all_mirrs = count($data);
$num_of_tested_mirrs = 0;
$common_patern = '/distrib/8/i586';
+ $common_patern = '/distrib/cauldron/i586';
// this huge regex magic achieved with a lot of help from great https://regex101.com/
$single_mirror_parsing_regex = '/\s*continent\s*=\s*(?<continent>\w*)\s*,\s*';
$single_mirror_parsing_regex .= '\s*zone\s*=\s*(?<zone>\w*)\s*,\s*';
@@ -239,7 +240,8 @@ class Downloads
} else if ($mirrorlist) {
$test_file = $item['url'].'/distrib/8/x86_64/media/core/updates/repodata/repomd.xml'; // when changing, please change $common_patern too
} else {
- $test_file = $item['url'].'/iso/8/torrents/Mageia-8-Live-Xfce-i586.torrent';
+ $test_file = $item['url'].'/iso/8/torrents/Mageia-9-Live-Xfce-i586.torrent';
+ $test_file = $item['url'].'/iso/cauldron/torrents/Mageia-9-beta1-Live-Xfce-i586.torrent';
}
if (false === @file_get_contents($test_file)) {
$num_dn++;