We can install or automate VCSA deployment using the CLI. VMware has already provided CLI option for the installation and completely documented solution.
You can refer VMware documentation below.
https://docs.vmware.com/en/VMware-vSphere/8.0/vsphere-vcenter-installation/GUID-C17AFF44-22DE-41F4-B85D-19B7A995E144.html
There are the following steps involved in installing VCSA using CLI
- JSON templates are available in the VCSA installation bundle which we have to use for the installation.
- Under the folder \vcsa-cli-installer\templates\install you can find the templates.
- embedded_vCSA_on_ESXi.json
- embedded_vCSA_on_VC.json
- embedded_vCSA_replication_on_ESXi.json
- embedded_vCSA_replication_on_VC.json
- vCSA_with_cluster_on_ESXi.json
- Copy the respective JSON template to the temp folder and update the required details.
- Once the JSON template is updated, you can run the following command to verify
-
1vcsa-deploy install --verify-template-only "path_to_json"
- If verification is successful then, the next command you can use for precheck. Note, precheck do not install VCSA.
-
1vcsa-deploy install --accept-eula --precheck-only "path_to_json"
- If the precheck is having any errors then resolve it and re-run the precheck
- The next command you can use to install VCSA
-
1vcsa-deploy install --accept-eula --no-esx-ssl-verify --no-ssl-certificate-verification "path_to_json"
- You can omit –no-esx-ssl-verify –no-ssl-certificate-verification in case you have validate certificates in place
- The installation will start for the VCSA, it will take approximately 30 to install VCSA completely.