From: Daniel Hokka Zakrisson Date: Sun, 24 Jun 2007 22:04:22 +0000 (+0000) Subject: Add a way to associate a distribution with a default template. X-Git-Tag: release-0.30.214~51 X-Git-Url: http://git.linux-vserver.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fac60eed96dfe149b45fd4e2b25ce4bc23de6829;p=util-vserver.git 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 --- 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