<?php
$URL_HANDLERS["*"] = "GLCASRepo";
+
class GLCASRepo {
function __construct($config)
{
function go($url)
{
- echo "i am the repo man, i repo the repo";
+ error_log("repo:go called");
+ GLCASpageBuilder($this, "body");
+ }
+
+ function body($url)
+ {
+ echo "for the repo, i am the repo $url";
+ }
+
+ function getRepoDetailsYum($url, $ismirrorlist=false)
+ {
+ $actionurl = $url."/repodata/repomd.xml";
+
+ error_log("Getting for action of $actionurl");
+
+ $ld = file_get_contents($actionurl);
+
+ // so here we try and get what this repository provides (os, version, arch), for yum this
+ // should come straight off the url... i.e. centos/6.0/os/x86_64/ (centos, 6.0, base os, 64bit arch)
+
+ if(!$ld) return false;
+
+ $glt["OS"] = "Fedora";
+ $glt["version"] = "15";
+ $glt["arch"] = "x86_64";
+
+ return $glt;
}
private $config;