How to download VCF Bundles using API
book
Article ID: 372387
calendar_today
Updated On:
Products
VMware SDDC Manager
VMware Cloud Foundation 5.x
VMware Cloud Foundation
Issue/Introduction
If bundles are not available to download through the SDDC Manager UI, you may need to download the bundles through the SDDC Manager API.
Environment
VMware Cloud Foundation 5.x
Resolution
- Create Token - Use Option (a) or Option (b)
- Using SDDC Manager API
- Open SDDC Manager UI > Developer Center > API Explorer.
- Browse to Tokens > POST /v1/tokens > Parameter
- Click on TokenCreationSpec on the right side to generate the spec
- Enter in the administrator username/password and press execute (you can leave the "apiKey" and "id Token" empty).
- Using CLI
-
SSH to SDDC Manager using vcf and su to root
- Run the below command to generate the Token
curl -X POST -H "Content-Type: application/json" -d '{"username": "<sso_username>","password": "<sso_password>"}' https://<sddc_manager_IP>/v1/tokens | json_pp
- Get the Bundle ID from the KB VMware Cloud Foundation - Upgrade Bundle Details
- Download the bundle
curl -k 'https://<sddc_manager_IP>/v1/bundles/<bundle id gathered from Step # 2>' -i -X PATCH \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN receievd from Step # 1>' \
-d '{
"bundleDownloadSpec" : {
"downloadNow" : true
}
}'
- The bundle should now be downloading and visible in the SDDC Manager UI
Feedback
thumb_up
Yes
thumb_down
No