Publish layered images from template

Layered images are virtual machines composited from the layers and settings specified in an image template. Using an image template, you can publish as many layered images as you need to a location in your Provisioning Service or hypervisor that you specify in the connector configuration.

When layered images are published, you can use scripts to perform important layer-specific steps. For example, you can activate Microsoft Office, which may need to be done before the virtual machine is used as a master disk for your deployment tools.

The mechanism used to run these scripts can vary, including our own kmssetup.cmd functionality, run-once support, or even running the scripts manually. After all of the scripts run or other manual steps are taken and the virtual machine is in the desired state, a guest OS shutdown is initiated either by the scripts or manually. If you use the kmssetup.cmd functionality, there is a documented process for initiating a shutdown after all layer scripts and other kmssetup functionality are complete.

To publish a layered image:

  1. In the Images module, select one or more image templates that you want to publish.
  2. On the Action menu, select Publish Layered Image.
  3. On the Confirm and Complete page, select Publish Layered Images. For each Image Template, this starts a task called Publishing Layered Image.
  4. Check the task bar, and when the disk for this image is created, click the link in the task description to advance to the next stage. Example link in task description:

    Example of task description with link

    The link leads you to a virtual machine whose state of creation depends upon the platform you are publishing to:

    • VMware vSphere (or provisioning service on it): The virtual machine is created, powered on as the guest OS, and running any scripts specified in the connector configuration.
    • Citrix Hypervisor, MS Hyper-V, Nutanix (or provisioning service on it): The virtual machine is created, but off. Log in as guest, and let the machine run any scripts specified in the connector configuration.
    • Azure (or Machine creation for Azure): A window for creating a virtual machine is open, but incomplete. Enter the values required, finish creating the machine, and power it on. The machine runs any scripts specified in the connector configuration.
  5. When the virtual machine is in the desired state, shut it down. The task status changes to Done.

  6. Use the information in the task description to navigate to the image in your environment.

Possible error message

If you receive the following error and you want to log into the published image to make changes, it must be through the local user and not a domain user.

This system was not shut down properly. Please log off immediately and contact your system administrator.

Publish layered images from template