diff options
-rw-r--r-- | modules/buildsystem/manifests/var/distros.pp | 3 | ||||
-rw-r--r-- | modules/buildsystem/templates/vhost_repository.conf | 5 |
2 files changed, 8 insertions, 0 deletions
diff --git a/modules/buildsystem/manifests/var/distros.pp b/modules/buildsystem/manifests/var/distros.pp index f97ad8b2..bef77c08 100644 --- a/modules/buildsystem/manifests/var/distros.pp +++ b/modules/buildsystem/manifests/var/distros.pp @@ -71,6 +71,9 @@ # }, # # set this if you want iurt to use bootstrap URL # 'iurt_use_bootstrap' => true, +# # set this if the distro is not mirrored. This is used to add +# # an Alias in the vhost. +# 'no_mirror' => true, # # list of IP or hostnames allowed to access this distro on the # # repository. If you don't want to filter allowed IPs, don't set # # this value diff --git a/modules/buildsystem/templates/vhost_repository.conf b/modules/buildsystem/templates/vhost_repository.conf index 6b5b67e5..39c4c689 100644 --- a/modules/buildsystem/templates/vhost_repository.conf +++ b/modules/buildsystem/templates/vhost_repository.conf @@ -2,6 +2,7 @@ mirror_root = scope.lookupvar('buildsystem::var::repository::mirror_root') mirror_reporoot = scope.lookupvar('buildsystem::var::repository::mirror_reporoot') bootstrap_reporoot = scope.lookupvar('buildsystem::var::repository::bootstrap_reporoot') +distribdir = scope.lookupvar('buildsystem::var::repository::distribdir') distros = scope.lookupvar('buildsystem::var::distros::distros') -%> <VirtualHost *:80> @@ -14,6 +15,10 @@ distros = scope.lookupvar('buildsystem::var::distros::distros') %> Alias /bootstrap/<%= distroname %>/ "<%= bootstrap_reporoot %>/<%= distroname %>/" +<%- if distro['no_mirror'] -%> + Alias /<%= distribdir %>/<%= distroname %>/ "<%= bootstrap_reporoot %>/<%= distroname %>/" +<%- end -%> + <Directory <%= bootstrap_reporoot %>/<%= distroname %>> Header append Cache-Control "public, must-revalidate" Order deny,allow |