-
Notifications
You must be signed in to change notification settings - Fork 1.9k
RHOSP bare metal worker support - OSDOCS-1276 #25167
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
134 changes: 134 additions & 0 deletions
134
modules/installation-osp-deploying-bare-metal-machines.adoc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,134 @@ | ||
| // Module included in the following assemblies: | ||
| // | ||
| // * installing/installing_openstack/installing-openstack-installer-custom.adoc | ||
| // * installing/installing_openstack/installing-openstack-user.adoc | ||
|
|
||
| ifeval::["{context}" == "installing-openstack-installer-custom"] | ||
| :osp-ipi: | ||
| endif::[] | ||
|
|
||
| [id="installation-osp-deploying-bare-metal-machines_{context}"] | ||
| = Deploying a cluster with bare metal machines | ||
|
|
||
| If you want your cluster to use bare metal machines, modify the | ||
| ifdef::osp-ipi[`install-config.yaml`] | ||
| ifndef::osp-ipi[`inventory.yaml`] | ||
| file. Your cluster can have both control plane and compute machines running on bare metal, or just compute machines. | ||
|
|
||
maxwelldb marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| Bare-metal compute machines are not supported on clusters that use Kuryr. | ||
|
|
||
| [NOTE] | ||
| ==== | ||
| Be sure that your `install-config.yaml` file reflects whether the {rh-openstack} network that you use for bare metal workers supports floating IP addresses or not. | ||
maxwelldb marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| ==== | ||
|
|
||
| .Prerequisites | ||
|
|
||
| * The {rh-openstack} link:https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/16.1/html/bare_metal_provisioning/index[Bare Metal service (Ironic)] is enabled and accessible via the {rh-openstack} Compute API. | ||
|
|
||
| * Bare metal is available as link:https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/16.1/html/bare_metal_provisioning/sect-configure#creating_the_bare_metal_flavor[a {rh-openstack} flavor]. | ||
|
|
||
| * The {rh-openstack} network supports both VM and bare metal server attachment. | ||
|
|
||
| * Your network configuration does not rely on a provider network. Provider networks are not supported. | ||
|
|
||
| * If you want to deploy the machines on a pre-existing network, a {rh-openstack} subnet is provisioned. | ||
|
|
||
| * If you want to deploy the machines on an installer-provisioned network, the {rh-openstack} Bare Metal service (Ironic) is able to listen for and interact with Preboot eXecution Environment (PXE) boot machines that run on tenant networks. | ||
|
|
||
| ifdef::osp-ipi[] | ||
| * You created an `install-config.yaml` file as part of the {product-title} installation process. | ||
| endif::osp-ipi[] | ||
|
|
||
| ifndef::osp-ipi[] | ||
| * You created an `inventory.yaml` file as part of the {product-title} installation process. | ||
| endif::osp-ipi[] | ||
|
|
||
| .Procedure | ||
|
|
||
| ifdef::osp-ipi[] | ||
| . In the `install-config.yaml` file, edit the flavors for machines: | ||
| .. If you want to use bare-metal control plane machines, change the value of `controlPlane.platform.openstack.type` to a bare metal flavor. | ||
| .. Change the value of `compute.platform.openstack.type` to a bare metal flavor. | ||
maxwelldb marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| .. If you want to deploy your machines on a pre-existing network, change the value of `platform.openstack.machinesSubnet` to the {rh-openstack} subnet UUID of the network. Control plane and compute machines must use the same subnet. | ||
| + | ||
| .An example bare metal `install-config.yaml` file | ||
| [source,yaml] | ||
| ---- | ||
| controlPlane: | ||
| platform: | ||
maxwelldb marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| openstack: | ||
| type: <bare_metal_control_plane_flavor> <1> | ||
| ... | ||
|
|
||
| compute: | ||
| - architecture: amd64 | ||
| hyperthreading: Enabled | ||
| name: worker | ||
| platform: | ||
| openstack: | ||
| type: <bare_metal_compute_flavor> <2> | ||
| replicas: 3 | ||
| ... | ||
|
|
||
| platform: | ||
| openstack: | ||
| machinesSubnet: <subnet_UUID> <3> | ||
| ... | ||
| ---- | ||
| <1> If you want to have bare-metal control plane machines, change this value to a bare metal flavor. | ||
| <2> Change this value to a bare metal flavor to use for compute machines. | ||
| <3> If you want to use a pre-existing network, change this value to the UUID of the {rh-openstack} subnet. | ||
|
|
||
|
|
||
| Use the updated `install-config.yaml` file to complete the installation process. | ||
| The compute machines that are created during deployment use the flavor that you | ||
| added to the file. | ||
| endif::osp-ipi[] | ||
|
|
||
| ifndef::osp-ipi[] | ||
| . In the `inventory.yaml` file, edit the flavors for machines: | ||
| .. If you want to use bare-metal control plane machines, change the value of `os_flavor_master` to a bare metal flavor. | ||
| .. Change the value of `os_flavor_worker` to a bare metal flavor. | ||
| + | ||
| .An example bare metal `inventory.yaml` file | ||
| [source,yaml] | ||
| ---- | ||
| all: | ||
| hosts: | ||
| localhost: | ||
| ansible_connection: local | ||
| ansible_python_interpreter: "{{ansible_playbook_python}}" | ||
|
|
||
| # User-provided values | ||
| os_subnet_range: '10.0.0.0/16' | ||
| os_flavor_master: 'my-bare-metal-flavor' <1> | ||
| os_flavor_worker: 'my-bare-metal-flavor' <2> | ||
| os_image_rhcos: 'rhcos' | ||
| os_external_network: 'external' | ||
| ... | ||
| ---- | ||
| <1> If you want to have bare-metal control plane machines, change this value to a bare metal flavor. | ||
maxwelldb marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| <2> Change this value to a bare metal flavor to use for compute machines. | ||
|
|
||
| Use the updated `inventory.yaml` file to complete the installation process. | ||
| Machines that are created during deployment use the flavor that you | ||
| added to the file. | ||
| endif::osp-ipi[] | ||
|
|
||
| [NOTE] | ||
| ==== | ||
| The installer may time out while waiting for bare metal machines to boot. | ||
|
|
||
| If the installer times out, restart and then complete the deployment by using the `wait-for` command of the installer. For example: | ||
|
|
||
| [source,terminal] | ||
| ---- | ||
| ./openshift-install wait-for install-complete --log-level debug | ||
| ---- | ||
| ==== | ||
|
|
||
| ifeval::["{context}" == "installing-openstack-installer-custom"] | ||
| :!osp-ipi: | ||
| endif::[] | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,93 @@ | ||
| [id="machineset-osp-adding-bare-metal_{context}"] | ||
| = Adding bare-metal compute machines to a {rh-openstack} cluster | ||
| // TODO | ||
| // Mothballed | ||
| // Reintroduce when feature is available. | ||
| You can add bare-metal compute machines to an {product-title} cluster after you deploy it | ||
| on {rh-openstack-first}. In this configuration, all machines are attached to an | ||
| existing, installer-provisioned network, and traffic between control plane and | ||
| compute machines is routed between subnets. | ||
|
|
||
| [NOTE] | ||
| ==== | ||
| Bare-metal compute machines are not supported on clusters that use Kuryr. | ||
| ==== | ||
|
|
||
| .Prerequisites | ||
|
|
||
| * The {rh-openstack} link:https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/16.1/html/bare_metal_provisioning/index[Bare Metal service (Ironic)] is enabled and accessible by using the {rh-openstack} Compute API. | ||
|
|
||
| * Bare metal is available as link:https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/16.1/html/bare_metal_provisioning/sect-configure#creating_the_bare_metal_flavor[an {rh-openstack} flavor]. | ||
|
|
||
| * You deployed a {product-title} cluster on installer-provisioned infrastructure. | ||
|
|
||
| * Your {rh-openstack} cloud provider is configured to route traffic between the installer-created VM | ||
| subnet and the pre-existing bare metal subnet. | ||
|
|
||
| .Procedure | ||
| . Create a file called `baremetalMachineSet.yaml`, and then add the bare metal flavor to it: | ||
| + | ||
| FIXME: May require update before publication. | ||
| .A sample bare metal MachineSet file | ||
maxwelldb marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| [source,yaml] | ||
| ---- | ||
| apiVersion: machine.openshift.io/v1beta1 | ||
| kind: MachineSet | ||
| metadata: | ||
| labels: | ||
| machine.openshift.io/cluster-api-cluster: <infrastructure_ID> | ||
| machine.openshift.io/cluster-api-machine-role: <node_role> | ||
| machine.openshift.io/cluster-api-machine-type: <node_role> | ||
| name: <infrastructure_ID>-<node_role> | ||
| namespace: openshift-machine-api | ||
| spec: | ||
| replicas: <number_of_replicas> | ||
| selector: | ||
| matchLabels: | ||
| machine.openshift.io/cluster-api-cluster: <infrastructure_ID> | ||
| machine.openshift.io/cluster-api-machineset: <infrastructure_ID>-<node_role> | ||
| template: | ||
| metadata: | ||
| labels: | ||
| machine.openshift.io/cluster-api-cluster: <infrastructure_ID> | ||
| machine.openshift.io/cluster-api-machine-role: <node_role> | ||
| machine.openshift.io/cluster-api-machine-type: <node_role> | ||
| machine.openshift.io/cluster-api-machineset: <infrastructure_ID>-<node_role> | ||
| spec: | ||
| providerSpec: | ||
| value: | ||
| apiVersion: openstackproviderconfig.openshift.io/v1alpha1 | ||
| cloudName: openstack | ||
| cloudsSecret: | ||
| name: openstack-cloud-credentials | ||
| namespace: openshift-machine-api | ||
| flavor: <nova_flavor> | ||
| image: <glance_image_name_or_location> | ||
| kind: OpenstackProviderSpec | ||
| networks: | ||
| - filter: {} | ||
| subnets: | ||
| - filter: | ||
| name: <subnet_name> | ||
| tags: openshiftClusterID=<infrastructure_ID> | ||
| securityGroups: | ||
| - filter: {} | ||
| name: <infrastructure_ID>-<node_role> | ||
| serverMetadata: | ||
| Name: <infrastructure_ID>-<node_role> | ||
| openshiftClusterID: <infrastructure_ID> | ||
| tags: | ||
| - openshiftClusterID=<infrastructure_ID> | ||
| trunk: true | ||
| userDataSecret: | ||
| name: <node_role>-user-data | ||
| ---- | ||
|
|
||
| . On a command line, to create the MachineSet resource, type: | ||
| + | ||
| [source,terminal] | ||
| ---- | ||
| oc create -v baremetalMachineSet.yaml | ||
| ---- | ||
|
|
||
| You can now use bare-metal compute machines in your {product-title} cluster. | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.