Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions pkg/bmc/access_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "ipxe",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand All @@ -462,7 +462,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "ipxe",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand All @@ -474,7 +474,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "ipxe",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand All @@ -498,7 +498,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "ipxe",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand All @@ -510,7 +510,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "redfish-virtual-media",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand All @@ -522,7 +522,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "redfish-virtual-media",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand All @@ -534,7 +534,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "redfish-virtual-media",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand Down Expand Up @@ -630,7 +630,7 @@ func TestStaticDriverInfo(t *testing.T) {
boot: "ilo-ipxe",
management: "",
power: "",
raid: "",
raid: "no-raid",
vendor: "",
},

Expand Down
2 changes: 1 addition & 1 deletion pkg/bmc/ibmc.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ func (a *ibmcAccessDetails) PowerInterface() string {
}

func (a *ibmcAccessDetails) RAIDInterface() string {
return ""
return "no-raid"
}

func (a *ibmcAccessDetails) VendorInterface() string {
Expand Down
2 changes: 1 addition & 1 deletion pkg/bmc/idrac.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ func (a *iDracAccessDetails) PowerInterface() string {
}

func (a *iDracAccessDetails) RAIDInterface() string {
return ""
return "no-raid"
}

func (a *iDracAccessDetails) VendorInterface() string {
Expand Down
2 changes: 1 addition & 1 deletion pkg/bmc/ilo4.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ func (a *iLOAccessDetails) PowerInterface() string {
}

func (a *iLOAccessDetails) RAIDInterface() string {
return ""
return "no-raid"
}

func (a *iLOAccessDetails) VendorInterface() string {
Expand Down
2 changes: 1 addition & 1 deletion pkg/bmc/ipmi.go
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ func (a *ipmiAccessDetails) PowerInterface() string {
}

func (a *ipmiAccessDetails) RAIDInterface() string {
return ""
return "no-raid"
}

func (a *ipmiAccessDetails) VendorInterface() string {
Expand Down
2 changes: 1 addition & 1 deletion pkg/bmc/redfish.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func (a *redfishAccessDetails) PowerInterface() string {
}

func (a *redfishAccessDetails) RAIDInterface() string {
return ""
return "no-raid"
}

func (a *redfishAccessDetails) VendorInterface() string {
Expand Down
2 changes: 1 addition & 1 deletion pkg/bmc/redfish_virtualmedia.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ func (a *redfishVirtualMediaAccessDetails) PowerInterface() string {
}

func (a *redfishVirtualMediaAccessDetails) RAIDInterface() string {
return ""
return "no-raid"
}

func (a *redfishVirtualMediaAccessDetails) VendorInterface() string {
Expand Down
4 changes: 2 additions & 2 deletions pkg/provisioner/ironic/ironic.go
Original file line number Diff line number Diff line change
Expand Up @@ -1234,7 +1234,7 @@ func (p *ironicProvisioner) ironicHasSameImage(ironicNode *nodes.Node) (sameImag

func (p *ironicProvisioner) buildManualCleaningSteps() (cleanSteps []nodes.CleanStep, err error) {
// Build raid clean steps
if p.bmcAccess.RAIDInterface() != "" {
if p.bmcAccess.RAIDInterface() != "no-raid" {
cleanSteps = append(cleanSteps, BuildRAIDCleanSteps(p.host.Status.Provisioning.RAID)...)
} else if p.host.Status.Provisioning.RAID != nil {
return nil, fmt.Errorf("RAID settings are defined, but the node's driver %s does not support RAID", p.bmcAccess.Driver())
Expand All @@ -1246,7 +1246,7 @@ func (p *ironicProvisioner) buildManualCleaningSteps() (cleanSteps []nodes.Clean
}

func (p *ironicProvisioner) startManualCleaning(ironicNode *nodes.Node) (success bool, result provisioner.Result, err error) {
if p.bmcAccess.RAIDInterface() != "" {
if p.bmcAccess.RAIDInterface() != "no-raid" {
// Set raid configuration
err = setTargetRAIDCfg(p, ironicNode)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion pkg/provisioner/ironic/testbmc/testbmc.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func (a *testAccessDetails) PowerInterface() string {
}

func (a *testAccessDetails) RAIDInterface() string {
return ""
return "no-raid"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about using a constant for such value?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we can probably think about creating possible values for raid as a constant (In a different PR I would say, since this is blocking deployments with virtual media)

}

func (a *testAccessDetails) VendorInterface() string {
Expand Down