During a VMware Cloud Foundation (VCF) bringup, where VMware Cloud Builder is performing deploying the VCF Management Domain, unforeseen issues can occur. Within the Cloud Builder UI or API, if a particular task had failed, you can easily retry the deployment without having to start all over again, which is certainly something I have benefited more than once!
When you retry the bringup workflow, it is using the original bringup specification which from the Cloud Builder UI can either be the VCF Deployment Workbook (XLS) or VCF Deployment Spec (JSON), which is to be expected as you are attempting to retry the exact same deployment.
However, in some cases you might need to adjust the bringup specification or if you made a typo but this is typically not allowed during a retry operation and would require a complete re-deployment. While deploying the newest VCF 5.1 release, I was testing out a new deployment scenario where I needed to append additional entries into the VCF Deployment JSON spec and I came to learn from one of our Engineers that I did not have to blow away the setup, but that I could retry using a modified bringup spec when using the Cloud Builder API!
To use the Cloud Builder API to retry a modified VCF bringup spec, you need to be using VCF 4.0.1 or later and have the original VCF Deployment JSON spec.
Step 1 - Login to Cloud Builder Appliance and locate the failed deployment UUID, which you can easily do by running the following command:
grep 'End of Orchestration with FAILURE for Execution ID' /var/log/vmware/vcf/bringup/vcf-bringup-debug.log | tail -1
In this example, the failed deployment UUID is 756270db-b9c0-4577-9832-42f1f3883417 which we will need to make a note of.
Step 2 - Copy your original VCF Deployment JSON spec with the modified changes into the Cloud Builder Appliance. In this example, I have named my modified spec modified-payload.json
Step 3 - Finally, we call the Cloud Builder PATCH API providing the deployment UUID in the URL along with the Cloud Builder admin credentials and the modified spec as shown in the example below:
curl -k -u admin:'VMware1!VMware1!' -X PATCH https://localhost/v1/sddcs/756270db-b9c0-4577-9832-42f1f3883417 -H "Content-Type: application/json" -d @modified-payload.json
If the modified bringup spec was accepted, you should now see the VCF deployment continue using the updated specification and you can now monitor the remainder progress using the Cloud Builder UI!
Definitely a handy trick for anyone that may have fat fingered a deployment specification or need to make a few more updates without having to redeploy!
Christopher says
The json payload in step 3 shows up as "*protected email*" in the post instead of the "-d(at)filename". Screenshot shows it correctly of course.
William Lam says
Yea, I've got a plugin that searches for anything that "looks" like an email and blocks it ... I've added a space which should render it correctly now