From b739b89b576b471e87e8a90b06a2ed654684d766 Mon Sep 17 00:00:00 2001 From: shibaPuppy Date: Wed, 31 May 2023 21:04:07 +0900 Subject: [PATCH] Change the power control of bmh --- baremetal/metal3machine_manager.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/baremetal/metal3machine_manager.go b/baremetal/metal3machine_manager.go index 7de1fecb01..e4f8a32fca 100644 --- a/baremetal/metal3machine_manager.go +++ b/baremetal/metal3machine_manager.go @@ -1156,7 +1156,9 @@ func (m *MachineManager) setHostSpec(ctx context.Context, host *bmov1alpha1.Bare } } - host.Spec.Online = true + if host.Status.Provisioning.State != bmov1alpha1.StateExternallyProvisioned { + host.Spec.Online = true + } return nil }