aboutsummaryrefslogtreecommitdiffstats
path: root/modules/auto_installation/manifests/init.pp
diff options
context:
space:
mode:
authorMichael Scherer <misc@mageia.org>2011-04-01 01:44:38 +0000
committerMichael Scherer <misc@mageia.org>2011-04-01 01:44:38 +0000
commit027555fb663b3ea375fe8173aa3bfd0fdb9f30ec (patch)
treeab019b6dff35364b97f54918fd9a7586e7591ac6 /modules/auto_installation/manifests/init.pp
parentac644e624e78510a3173c542057c27a1d2395ae3 (diff)
downloadpuppet-027555fb663b3ea375fe8173aa3bfd0fdb9f30ec.tar
puppet-027555fb663b3ea375fe8173aa3bfd0fdb9f30ec.tar.gz
puppet-027555fb663b3ea375fe8173aa3bfd0fdb9f30ec.tar.bz2
puppet-027555fb663b3ea375fe8173aa3bfd0fdb9f30ec.tar.xz
puppet-027555fb663b3ea375fe8173aa3bfd0fdb9f30ec.zip
- use exported ressource to populate the pxe menu
Diffstat (limited to 'modules/auto_installation/manifests/init.pp')
-rw-r--r--modules/auto_installation/manifests/init.pp22
1 files changed, 19 insertions, 3 deletions
diff --git a/modules/auto_installation/manifests/init.pp b/modules/auto_installation/manifests/init.pp
index fb327518..19c20680 100644
--- a/modules/auto_installation/manifests/init.pp
+++ b/modules/auto_installation/manifests/init.pp
@@ -41,13 +41,29 @@ class auto_installation {
ensure => directory,
}
-
+ # TODO make it tag aware
+ $menu_entries = list_exported_ressources('Auto_installation::Pxe_menu_base')
# default file should have exported ressources
file { "$pxe_dir/pxelinux.cfg/default":
ensure => present,
content => template('auto_installation/default'),
- }
-
+ }
+ Auto_installation::Pxe_menu_base <<| tag == $fqdn |>>
+ }
+
+ define pxe_menu_base($content) {
+ include auto_installation::variables
+ file { "$auto_installation::variables::pxe_menu_dir/$name":
+ ensure => present,
+ content => $content,
+ }
+ }
+
+ define pxe_menu_entry($kernel_path, $append) {
+ @@auto_installation::pxe_menu_base { $name:
+ tag => $fqdn,
+ content => template('auto_installation/menu'),
+ }
}
# define pxe_linux_entry