|
1 | 1 | # OCP4 on VMware vSphere UPI Automation |
2 | 2 |
|
3 | | -The goal of this repo is to make deploying and redeploying a new Openshift v4 cluster a snap. The document looks long but after you have used it till end once, you will appreciate how quickly VMs come up in vCenter for you to start working with. |
| 3 | +The goal of this repo is to make deploying and redeploying a new Openshift v4 cluster a snap. The document looks long but after you have used it till the end once, you will appreciate how quickly VMs come up in vCenter for you to start working with. |
4 | 4 |
|
5 | 5 | Using the same repo and with minor tweaks, it can be applied to any version of Openshift higher than the current version of 4.2. |
6 | 6 |
|
7 | 7 | ## Prerequisites |
8 | 8 |
|
9 | 9 | 1. vSphere ESXi and vCenter 6.7 installed |
10 | | -2. A datacenter created with vSphere host added to it |
| 10 | +2. A datacenter created with a vSphere host added to it |
11 | 11 | 3. **VM and Template folder** created with the same name as the **Openshift cluster name** you would like to use, as described in the [documentation](https://docs.openshift.com/container-platform/4.2/installing/installing_vsphere/installing-vsphere.html#installation-vsphere-machines_installing-vsphere) |
12 | 12 | 4. The OVF template deployed in the ***same folder*** from the OVA file [located here](https://mirror.openshift.com/pub/openshift-v4/dependencies/rhcos/4.2/latest/rhcos-4.2.0-x86_64-vmware.ova) using instructions from **#6** step of the same documentation as in the previous step. Once deployed, on the template name, right-click and select **Edit Settings** and do the following: |
13 | | - * Under `Virtual Hardware` 🠮 `Network adapter 1` 🠮 Highlight and delete it by clicking on the x symbol on the right. ***This is an important step if you would like to use the mac addresses as defined in the file*** |
14 | | - * Under the `VM Options` 🠮 `Advanced` 🠮 Latency Sensitivity; set it to **High** |
15 | | - * Under the `VM Options` 🠮 `Advanced` 🠮 `Configuration Parameters` 🠮 Edit Configuration; add the following param (name, value) respectively: |
| 13 | + * Under `Virtual Hardware` 🠮 `Network adapter 1` 🠮 Highlight and delete it by clicking on the `x` symbol on the right. ***This is an important step if you would like to use the mac addresses as defined in the file*** |
| 14 | + * Under the `VM Options` 🠮 `Advanced` 🠮 `Latency Sensitivity`; set it to **High** |
| 15 | + * Under the `VM Options` 🠮 `Advanced` 🠮 `Configuration Parameters` 🠮 `Edit Configuration`; add the following param (name, value) respectively: |
16 | 16 | 1. `disk.EnableUUID`, TRUE |
17 | 17 | 2. `guestinfo.ignition.config.data.encoding`, base64 |
18 | 18 | 3. `guestinfo.ignition.config.data`, blah |
19 | 19 | * Save the template |
20 | 20 | 5. Ideally have [helper node](https://github.com/christianh814/ocp4-upi-helpernode) running in the same network to provide all the necessary services such as [DHCP/DNS/HAProxy as LB/FTP Server] |
21 | | -6. Ansible 2.8.5 installed on the machine where this repo is cloned |
| 21 | +6. Ansible 2.8.5 installed on the machine where this repo is cloned |
| 22 | + * For this specific version of Ansible you can run the command `sudo dnf -y install ansible-2.8.5` |
22 | 23 |
|
23 | 24 | ## Automatic generation of ignition and other supporting files |
24 | 25 |
|
25 | 26 | ### Prerequisites |
26 | 27 |
|
27 | 28 | 1. Get the ***pull secret*** from [here](https://cloud.redhat.com/openshift/install/vsphere/user-provisioned) |
28 | | -2. Generate a ssh key pair as per [instructions](https://docs.openshift.com/container-platform/4.2/installing/installing_vsphere/installing-vsphere.html#ssh-agent-using_installing-vsphere). The private key will then be used to log into bootstrap/master and worker nodes |
29 | | -3. Get the vcenter details: |
| 29 | +2. Generate a SSH key pair as per [instructions](https://docs.openshift.com/container-platform/4.2/installing/installing_vsphere/installing-vsphere.html#ssh-agent-using_installing-vsphere). The private key will then be used to log into bootstrap/master and worker nodes |
| 30 | +3. Get the vCenter details: |
30 | 31 | 1. IP Address |
31 | 32 | 2. Username |
32 | 33 | 3. Password |
@@ -102,7 +103,7 @@ In vCenter all VMs (bootstrap, master0-2, worker0-2) generated in the designated |
102 | 103 |
|
103 | 104 | In vCenter click on the ESXi Host (IP address) 🠮 Click on VMs tab 🠮 Cntrl-select all of the 7 machines 🠮 Right-click and choose Power 🠮 Power On |
104 | 105 |
|
105 | | -If everything goes well you should be able to log into all of the machines (from the machine which has the private key of the ssh key pair that was generated) using the private key generated in prerequistes. On **bootstrap** node running the following command will help understand if the masters are (being) setup: |
| 106 | +If everything goes well you should be able to log into all of the machines (from the machine which has the private key of the SSH key pair that was generated) using the private key generated in prerequistes. On **bootstrap** node running the following command will help understand if the masters are (being) setup: |
106 | 107 |
|
107 | 108 | ```sh |
108 | 109 | journalctl -b -f -u bootkube.service |
|
0 commit comments