From fac60eed96dfe149b45fd4e2b25ce4bc23de6829 Mon Sep 17 00:00:00 2001 From: Daniel Hokka Zakrisson Date: Sun, 24 Jun 2007 22:04:22 +0000 Subject: [PATCH] Add a way to associate a distribution with a default template. git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@2554 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- doc/configuration.xml | 5 +++++ scripts/vserver-build.template | 7 +++++++ 2 files changed, 12 insertions(+) diff --git a/doc/configuration.xml b/doc/configuration.xml index 9134178..8db75d1 100644 --- a/doc/configuration.xml +++ b/doc/configuration.xml @@ -412,6 +412,11 @@ this distribution. + + +Symlink to the default template for this distribution. + + diff --git a/scripts/vserver-build.template b/scripts/vserver-build.template index dc5d1c0..27616cb 100644 --- a/scripts/vserver-build.template +++ b/scripts/vserver-build.template @@ -48,6 +48,13 @@ done getDistribution '' 1 +for d in "$__CONFDIR/.distributions/$DISTRIBUTION" \ + "$__DISTRIBDIR/$DISTRIBUTION"; do + if test -r "$d/template"; then + TEMPLATE=( "$d/template" "${TEMPLATE[@]}" ) + fi +done + base.init test -z "$use_pkgmgmt" || pkgmgmt.initVariables -- 1.8.1.5