VMware recently announced the availability of the Cloud Director Extension SDK for developing solution add-ons and the solution add-on development lifecycle. It provides tools for writing, building, testing, and packaging VMware Cloud Director UI plugins, runtime definitions, roles and rights, vApps and related network services and policies, and their lifecycle operations.
Beginning in VMware Cloud Director 10.4.1, you can use VMware Cloud Director Solution add-ons UI to extend a VMware Cloud Director offering with additional value-added functionality. The UI allows you to manage the resources and life cycle of solution add-ons. a A solution add-on is custom built for VMware Cloud Director in the extensibility ecosystem and can include both UI and API extensions together with their backend services and lifecycle management.
The roles in the solution add-on ecosystem are Vendor, Provider, and Tenant.
Vendors are the creators of solution add-ons who use the SDK to create services that complement VMware Cloud Director service, such as container service extension, third-party software vendors, Kubernetes service, and others.
Providers are the operators of solution add-ons in the VMware Cloud Director on-premises or VMware Cloud Director service environment.
Tenants are the consumers of the business outcomes brought about by a solution add-on, such as self-service of Kubernetes clusters, databases, UI extensions with back-office properties, and more.
Setting up the Development Environment
To prepare an environment to use the VMware Cloud Director extension SDK, perform the following, which are documented in the VMware Developer guide at Setting up the Development Environment. The following instructions were performed on Ubuntu desktop 20.04.
- Install docker version 18.09 or higher per the instructions in the pre-requisites in the link above.
- The dockerx plugin is install as part of the docker desktop that is installed.
- Download “vcd-ext-shell” from https://packages.vmware.com/vcd-ext/
- Run the following to make vcd-ext-shell executable from bash:
- echo ‘export PATH=$PATH:<path to vcd-ext-shell>’ >> ~/.bash_profile
- chmod a+x vcd-ext-shell
- ./vcd-ext-shell , which whould enter into the shell as shown below:
- You can see the current version by running the “about” command and entering “version”:
- Configure a vendor certificate to sign all files in the resulting ISO:
- In the vcd-ext-shell, run “setup” and then run “vendor-certificate”:
- Self-Signed should only be used during the development cycle; when releasing it to production it is recommended to use a publicly trusted certificate:
- Run “generate” to setup a self-signed certificate.
- Run “generate” to setup a self-signed certificate.
- Publicly Trusted Certificate:
- Run “set” and specify –certificate /path/to/cert/cert.cer –private-key /path/to/key/key.pem
- Run “set” and specify –certificate /path/to/cert/cert.cer –private-key /path/to/key/key.pem
- Self-Signed should only be used during the development cycle; when releasing it to production it is recommended to use a publicly trusted certificate:
- In the vcd-ext-shell, run “setup” and then run “vendor-certificate”:
- Set an encryption key if you need to encrypt credentials on other types of secrets provided as user input. The data will be encrypted with the key defined explicitly by the provider or implicitly generated by VMware Cloud Director.
- Run “encryption-key /path/to/key/key.aes”
- Run “encryption-key /path/to/key/key.aes”
- Add one or more VMware Cloud Director environments for implementation and test for the add-on .
- Run “cloud-director add –host <fqdn.of.vcd> –username <provider-user-name> –password <password-for-provider-user> (or use password file). Once added, it will show you the active host just specified.
- You can add additional hosts by repeating the previous command with the other host name.
- You can show the current active host with “setup cloud-director print”
- You can switch active hosts if you specified more than one with “setup cloud-director active –host “
- Run “cloud-director add –host <fqdn.of.vcd> –username <provider-user-name> –password <password-for-provider-user> (or use password file). Once added, it will show you the active host just specified.
- Set whether you want to participate in the VMware’s Customer Experience Improvement Program (CEIP).
- To specify whether to participate in CEIP, run “setup ceip on” to turn on, “setup ceip off” to turn off, or “setup ceip print” to show the current CEIP participation status.
- Set the Extension Library to bootstrap a new project or add an element to an existing project using a prescribed library. In order to do so one or more repositories can be configured Default preconfigured public repository is https://github.com/vmware/cloud-director-extension-standard-library
- Run “setup extension-library add https://path_to_repository/”
- Run “setup extension-library add https://path_to_repository/”
The next steps are to build your add-on and exploring the lifecycle process, see Building a Simple Solution Add-On.
See the following VCPP Feature Friday video on the VMware Cloud Director Extension SDK.