From 6e8dab2aa2b1e1df4f38bd7811cb1dcbfac43058 Mon Sep 17 00:00:00 2001 From: Omer Tuchfeld Date: Wed, 15 Sep 2021 18:01:26 +0200 Subject: [PATCH] Block `create cluster` if bootstrapInPlace is set in install-config bootstrapInPlace configuration is only meant for generating ignition and embedding it manually in an RHCOS ISO. It is not meant for IPI installation. It seems that trying to do single-node IPI installation with this configuration set in the install-config file leads to odd installation failures with confusing error messages. This commit makes it so that the error is much earlier and more clear. --- pkg/asset/cluster/cluster.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkg/asset/cluster/cluster.go b/pkg/asset/cluster/cluster.go index b6e3823631..a933d1bb9f 100644 --- a/pkg/asset/cluster/cluster.go +++ b/pkg/asset/cluster/cluster.go @@ -67,6 +67,10 @@ func (c *Cluster) Generate(parents asset.Parents) (err error) { return errors.New("cluster cannot be created with platform set to 'none'") } + if installConfig.Config.BootstrapInPlace != nil { + return errors.New("cluster cannot be created with bootstrapInPlace set") + } + platform := installConfig.Config.Platform.Name() stages := platformstages.StagesForPlatform(platform)