How to set a root password for the Dataplane Node on Red Hat OpenStack Services on OpenShift

Solution Verified - Updated -

Environment

  • Red Hat OpenStack Services on OpenShift 18.0

Issue

  • How to set a root password for the Dataplane Node?

Resolution

When provisioning dataplane nodes with Ironic (via OpenStackDataPlaneNodeSet), to configure a root password by using the passwordSecret field is the way.
This allows you to securely inject a password during the provisioning process.

Step 1: Create a Secret

For Example,

apiVersion: v1
kind: Secret
metadata:
  name: bm-password-secret
  namespace: openstack
type: Opaque
data:
  NodeRootPassword: <root_password_base64_encoded>

Create the Secret CR with this file:

$ oc create -f <bm-password-secret>.yaml -n openstack

Step 2: Reference the Secret in your NodeSet.

For Example,

apiVersion: dataplane.openstack.org/v1beta1
kind: OpenStackDataPlaneNodeSet
metadata:
  name: openstack-edpm
  namespace: openstack
spec:
  preProvisioned: false
  baremetalSetTemplate:
    passwordSecret:
      name: bm-password-secret
      namespace: openstack

With this configuration, Ironic will inject the root password into the node image during deployment.

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.

Comments