aboutsummaryrefslogtreecommitdiffstats
path: root/modules/buildsystem
diff options
context:
space:
mode:
Diffstat (limited to 'modules/buildsystem')
-rw-r--r--modules/buildsystem/manifests/mainnode.pp2
-rw-r--r--modules/buildsystem/manifests/media_cfg.pp3
-rw-r--r--modules/buildsystem/manifests/repository.pp3
-rw-r--r--modules/buildsystem/manifests/var/repository.pp7
-rw-r--r--modules/buildsystem/manifests/youri_submit.pp2
-rw-r--r--modules/buildsystem/templates/vhost_repository.conf1
6 files changed, 13 insertions, 5 deletions
diff --git a/modules/buildsystem/manifests/mainnode.pp b/modules/buildsystem/manifests/mainnode.pp
index c3002086..d00704a5 100644
--- a/modules/buildsystem/manifests/mainnode.pp
+++ b/modules/buildsystem/manifests/mainnode.pp
@@ -1,4 +1,5 @@
class buildsystem::mainnode {
+ include buildsystem::var::repository
include buildsystem::base
include buildsystem::iurt::user
include buildsystem::scheduler
@@ -17,7 +18,6 @@ class buildsystem::mainnode {
ssh::auth::server { [$sched_login, $build_login]: }
- $mirror_root = '/distrib/mirror'
apache::vhost::other_app { "repository.$::domain":
vhost_file => 'buildsystem/vhost_repository.conf',
}
diff --git a/modules/buildsystem/manifests/media_cfg.pp b/modules/buildsystem/manifests/media_cfg.pp
index 5418e5d8..327468e3 100644
--- a/modules/buildsystem/manifests/media_cfg.pp
+++ b/modules/buildsystem/manifests/media_cfg.pp
@@ -1,8 +1,9 @@
define buildsystem::media_cfg($distro, $arch, $templatefile = 'buildsystem/media.cfg') {
+ include buildsystem::var::repository
include buildsystem::var::scheduler
include buildsystem::repository
- file { "${buildsystem::repository::dir}/distrib/${distro}/${arch}/media/media_info/media.cfg":
+ file { "${buildsystem::var::repository::bootstrap_reporoot}/distrib/${distro}/${arch}/media/media_info/media.cfg":
owner => $buildsystem::base::sched_login,
group => $buildsystem::base::sched_login,
content => template($templatefile),
diff --git a/modules/buildsystem/manifests/repository.pp b/modules/buildsystem/manifests/repository.pp
index 19e69eff..3b0c100d 100644
--- a/modules/buildsystem/manifests/repository.pp
+++ b/modules/buildsystem/manifests/repository.pp
@@ -1,6 +1,5 @@
class buildsystem::repository {
- $dir = '/distrib/bootstrap'
- file { $dir:
+ file { $buildsystem::var::repository::bootstrap_reporoot:
ensure => directory,
}
}
diff --git a/modules/buildsystem/manifests/var/repository.pp b/modules/buildsystem/manifests/var/repository.pp
new file mode 100644
index 00000000..ebf3e3d9
--- /dev/null
+++ b/modules/buildsystem/manifests/var/repository.pp
@@ -0,0 +1,7 @@
+class buildsystem::var::repository(
+ $bootstrap_reporoot = '/distrib/bootstrap',
+ $mirror_root = '/distrib/mirror',
+ $distribdir = 'distrib',
+) {
+ $mirror_reporoot = "${mirror_root}/${distribdir}"
+}
diff --git a/modules/buildsystem/manifests/youri_submit.pp b/modules/buildsystem/manifests/youri_submit.pp
index 5a70b1c4..84b283e9 100644
--- a/modules/buildsystem/manifests/youri_submit.pp
+++ b/modules/buildsystem/manifests/youri_submit.pp
@@ -4,7 +4,7 @@ class buildsystem::youri_submit {
include buildsystem::repository
include buildsystem::var::scheduler
- $repository_root = $buildsystem::repository::dir
+ $repository_root = $buildsystem::var::repository::bootstrap_reporoot
$sched_home_dir = $buildsystem::var::scheduler::homedir
$sched_login = $buildsystem::var::scheduler::login
$packages_archivedir = "$sched_home_dir/old"
diff --git a/modules/buildsystem/templates/vhost_repository.conf b/modules/buildsystem/templates/vhost_repository.conf
index 176b7f39..55259cc1 100644
--- a/modules/buildsystem/templates/vhost_repository.conf
+++ b/modules/buildsystem/templates/vhost_repository.conf
@@ -2,6 +2,7 @@
# FIXME: add a reverse lookup for IPv6 adresses
# allowed hosts are: valstar, ecosse, jonund
buildsystem_nodes = "2a02:2178:2:7::3/64 2a02:2178:2:7::4/64 2a02:2178:2:7::5/64"
+mirror_root = scope.lookupvar('buildsystem::var::repository::mirror_root')
%>
<VirtualHost *:80>