func (i *IDrac8) PowerCycleBmc() (bool, error) {
	output, err := i.sshClient.Run("racadm racreset hard")
	if err != nil {
		return false, fmt.Errorf("output: %q: %w", output, err)
	}
	if strings.Contains(output, "initiated successfully") {
		return true, nil
	}
	return false, fmt.Errorf(output)
}
PowerCycleBmc reboots the bmc we are connected to
package idrac8
import (
	"fmt"
	"net/url"
	"regexp"
	"strings"
)
func (i *IDrac8) PowerCycle() (bool, error) {
	output, err := i.sshClient.Run("racadm serveraction hardreset")
	if err != nil {
		return false, fmt.Errorf("output: %q: %w", output, err)
	}
	if strings.Contains(output, "successful") {
		return true, nil
	}
	return false, fmt.Errorf(output)
}