bootv2 support

This commit is contained in:
Mikaël Cluseau
2022-04-28 03:33:19 +02:00
parent 0d298c9951
commit 16a0ff0823
17 changed files with 1969 additions and 80 deletions

View File

@ -231,14 +231,15 @@ type Group struct {
Labels map[string]string
Annotations map[string]string
Master bool
IPXE string
Kernel string
Initrd string
Config string
StaticPods string `yaml:"static_pods"`
Versions map[string]string
Vars Vars
Master bool
IPXE string
Kernel string
Initrd string
BootstrapConfig string `yaml:"bootstrap_config"`
Config string
StaticPods string `yaml:"static_pods"`
Versions map[string]string
Vars Vars
}
// Vars store user-defined key-values

View File

@ -124,6 +124,11 @@ func FromDir(dirPath, defaultsPath string) (*Config, error) {
return nil, err
}
group.BootstrapConfig, err = template(group.Rev(), "configs", group.BootstrapConfig, &config.Configs)
if err != nil {
return nil, fmt.Errorf("failed to load config for group %q: %v", name, err)
}
group.Config, err = template(group.Rev(), "configs", group.Config, &config.Configs)
if err != nil {
return nil, fmt.Errorf("failed to load config for group %q: %v", name, err)