Preparing a Solution OVF to Use the Integrated Solution Installer
You can prepare a virtual machine with software and configuration metadata that work in conjunction with the vSphere Client to register a plug-in solution when the virtual machine starts up in a production environment.
Prerequisites
- vCenter Server 6.7 or later.
- An OVA package that contains a virtual machine with virtual hardware version 11 or later. PhotonOS, as used in this procedure, is recommended.
- rootoradministratoraccess to the guest operating system.
- (If you choose to use Docker to downloadnginx) access to the Docker Hub.
Outline of Steps to Prepare a Plug-in Server for Self-Registration and Installation
- Acquire the OVA File for Photon OS, virtual hardware version 11
- Use the vSphere Client to install the OVA in a vSphere environment
- Configure vAPP options for deployment in a production environment
- Run the virtual machine and set therootpassword in the guest OS
- Installing VMware Tools if needed
- Copy startup files to the/etc/rc.d/directory
When a user deploys a virtual machine from the finished OVF template, the virtual machine starts the plug-in web server in the guest OS and registers it with vCenter Server.
Acquire the OVA File for Photon OS
Photon OS is an open-source, security-hardened, enterprise-grade Linux distribution designed for Cloud and Edge applications.
You can download a Photon OS OVA with virtual hardware v11 from https://github.com/vmware/photon/wiki/Downloading-Photon-OS
Download Photon OS from GitHub

Install the OVA in a vSphere Environment
You need to install the virtual machine in an environment where you can modify its configuration and make some changes in the guest OS. To install the OVA, use the Deploy OVF Template wizard in the vSphere Client.
- Right-click any inventory object that is a valid parent object of a virtual machine, such as a data center, folder, cluster, resource pool, or host.
- SelectDeploy OVF Template.
- In the first step of the wizard,Select an OVF template, chooseLocal file.
- ClickUPLOAD FILESand choose the OVA file you downloaded.
- ClickNEXTand complete the Deploy OVF Template wizard.
The Deploy OVF Template wizard

Configure vApp Options
After you install the virtual machine in your development environment, you configure certain vApp properties that will affect the virtual machine when it is deployed to a production environment.
- Navigate to the deployed virtual machine name in the navigation pane on the left.
- Click theConfiguretab.
- Select> .Settings > VApp Options
- Click theEDITbutton near the top of the VApp Options panel.
On the IP Allocation tab, select network constraints for the virtual machine.
- In the Authoring section, choose one or both of the network protocols (IPv4, IPv6, or both) for the vApp production environment. The choices you make in the Authoring section constrain the choices available in the Deployment section.If you select OVF Environment in the Authoring section...Choose IP pool settings in the Deployment section.If you choose DHCP in the Authoring section...DHCP service must be available on the vSphere networks where the vApp will be deployed.If you make no selections in the Authoring section...IP addresses must be assigned manually when the vApp is deployed.
Selecting IP Allocation Choices

On the
OVF Details
tab of the Edit vApp Options window, in the OVF environment transport
section, enable VMware Tools. When the virtual machine is deployed in a production environment, it will use VMware Tools to read solution properties that were configured in the OVF template. These properties will be injected into the plug-in registration request.Selecting OVF Details

On the
Details
tab of the Edit vApp Options window, specify a vendor-supplied product name for the plug-in solution.Entering Vendor Information

Configure Solution Properties in the OVF
When the virtual machine starts as a plug-in in a production environment, it needs to register itself with vCenter Server. Before you deploy the plug-in, you must configure the OVF template with several solution properties that will be injected into the registration record during startup. These include the solution ID, the plug-in ID, and other properties.
- Navigate to the deployed virtual machine name in the navigation pane on the left
- Power off the virtual machine if it is powered on.
- Select theConfiguretab in the selection pane on the left.
- Select.
- In the vApp Options pane, scroll down to the Properties section.
Adding VApp Properties

Click
ADD
to add each new property. Configure the OVF environment with required properties, as shown in the following table. Default values are required, and must match the choice list value.
Optional values and best practices are described in Integrated Installer Solution Metadata.
Property Key | Type | Example Choice List | Example Default Value |
---|---|---|---|
vmw.vsphereui.solutioninstall.solutionId | string choice | "com.example.solution.id" | com.example.solution.id |
Choice list contains a single vendor-defined element. For example: "com.example.solution.id" | |||
vmw.vsphereui.solutioninstall.pluginId | string choice | "com.example.plugin.id" | com.example.plugin.id |
Choice list contains a single vendor-defined element. For example: "com.example.plugin.id". Value may be same as solution ID. | |||
vmw.vsphereui.solutioninstall.vCenterSupport | string choice | "Single" | Single |
Choice list contains either "Single" or "Multiple" to indicate whether the solution supports one or many vCenter Server instances. |
Property keys are case sensitive.
The OVF properties will be assigned values the next time the virtual machine is powered on. The values must be assigned before you export the OVF template.
For more information about these properties and other optional properties, see Integrated Installer Solution Metadata.
Upgrade VM Compatibility
To be sure that the guest OS will be supported by the host when it is deployed, upgrade compatibility to
ESXi 6.7 Update 2 and later
.
- Power off the virtual machine, if running.
- From the ACTIONS menu, choose.Upgrading Compatibility for the Virtual Machine
- In the Configure VM Compatibility dialog, chooseESXi 6.7 U2 and laterfrom theCompatible withpop-up menu.Upgrade VM Compatibility Dialog
Set the root Password in the Guest OS
root
Password in the Guest OSWhen you download the OVA, the root password for the guest OS is insecure. You must change the password before you deploy the virtual machine in a production environment.
- Power on the virtual machine.
- Open a Web Console or Remote Console window to the guest OS.
- The default root password for the Photon OS guest OS ischangeme.
- Set a new, secure, root password.
- Make a note of the new password, in case you need to update the software or alter the configuration in the future.
Install Your Web Application Server in the Guest OS
The virtual machine needs a plug-in server to handle REST queries from the plug-in user interface. You can install the SDK sample starter or other web server, according to your preference.
To install the remote plug-in sample starter provided in the vSphere Client SDK:
- Customize the sample starter as needed for your solution.
- Build the remote-plugin-sample-starter from the SDK.
- Copy the remote-plugin-sample-starter-VERSION.jar into the guest OS. (for this example, we use the /root/ folder of the VM).# cd /root # scp myuserid@mydevbox.example.com:/html-client-sdk/samples/remote-plugin-sample-starter/target/*.jar .
Install VMware Tools
If you are using the Photon OS OVA downloaded from github as described in the first step of this procedure, VMware Tools is already installed in the guest. Otherwise, you might need to install VMware Tools manually. In the vSphere Client Hosts and Clusters view, right-click your virtual machine and select https://kb.vmware.com/s/article/2004754.
. For more detailed instructions, see the knowledge base article Copy Startup Files into the Guest OS
When the virtual machine starts up in a production environment, it needs to run startup scripts to register itself with vCenter Server. You must install the scripts in the Linux guest OS before you deploy the virtual machine in a production environment.
- Copy the filesrc.localandvsphere_ui_request.pyfrom the SDK directory/samples/solutioninstall/to the directory/etc/rc.d/in the guest OS.# cd /etc/rc.d # scp myuserid@mydevbox.example.com:/html-client-sdk/samples/solutioninstall/rc.local . # scp myuserid@mydevbox.example.com:/html-client-sdk/samples/solutioninstall/vsphere_ui_request.py .
- Set execute permissions on the files in the guest OS.# chmod +x /etc/rc.d/rc.local # chmod +x /etc/rc.d/vsphere_ui_request.py
When you deploy the virtual machine as a plug-in in vCenter Server, the guest OS runs
rc.local
, which in turn runs vsphere_ui_request.py
. The request script uses VMware Tools to read the solution properties, then builds a registration request and sends it to vCenter Server.If you install a web server other than the remote plug-in sample starter, you can customize
rc.local
, which is a bash script, or write your own script along similar lines. The script does the following actions:
- Reads solution metadata
- Installs a JDK
- Opens a firewall port for incoming HTTPS requests
- Starts the web server
- Launchesvsphere_ui_request.pyto send the plug-in registration request
Note: If you customize the script, it is important that the vCenter Server thumbprint is verified as part of making the request to the vSphere UI.
Export a New OVF Template
After you configure VMware Tools, install the startup script, configure injectable solution properties, and install your plug-in web server, you can export the virtual machine as an OVF template that is available to deploy in your production environment.
- Power off the virtual machine.
- Export the virtual machine as an OVF, using theaction.In the Export OVF Template dialog, supply a name and description for the template.
Exporting an OVF Template

Related Resources
- PhotonOS documentation: https://vmware.github.io/photon/docs/
- nginx downloads: https://hub.docker.com/_/nginx/