[et-mgmt-tools] issue with templating and substitution

Jim Wildman jim at rossberry.com
Wed May 23 04:11:59 UTC 2007

Given the following snippet in default.ks

cat << YUMEND > /etc/yum.repos.d/default.$lbuild.repo
[$lbuild base]
name = $lbuild base repo
baseurl =$lbuild/RPMS.os

[$lbuild updates]
name = $lbuild updates repo
baseurl =$lbuild/RPMS.updates

[$lbuild rpmforge]
name = $lbuild rpmforge repo
baseurl =$lbuild/RPMS.rpmforge

and a ksmeta for this profile of
ks metadata     : {'lbuild': 'centos5-i386'}

Cobbler will successfully replace every instance of $lbuild with 
centos5-i386 except the _first_ one (the one in the 'cat' line).
ie, the file ends up named 'default..repo'.  I've tried $$lbuild (got me
the PID of the cobbler sync I think), and \$ (got me nothing), and
yum.repos.d/$lbuild.repo (which got me a hidden file named .repo which
is why I added the 'default').


root at dl380 cobbler]# rpm -q cobbler

Host is centos4

Jim Wildman, CISSP, RHCE       jim at rossberry.com http://www.rossberry.com
"Society in every state is a blessing, but Government, even in its best
state, is a necessary evil; in its worst state, an intolerable one."
Thomas Paine

More information about the et-mgmt-tools mailing list