# Configuring Virtual Images

## System Images

System Virtual Images are pre-configured with metadata and have Cloud-Init or Cloudbase-Init installed. These images are ready to be provisioned with no configuration necessary, however it is required to populate Administration > Settings > Provisioning, Cloud-Init section, with user data as well as User Profile(s) users data when creating additional users prior to provisioning, as the user data from these sections is required when provisioning System provided Virtual Images.

NOTE

System Images settings are not editable.

## User Images

Typically HPE Morpheus Enterprise does not have sufficient metatdata to successfully provision synced User Images. After integrating clouds and User Images have synced, it is highly recommended to configure the images prior to provisioning.

### To edit and configure an existing Virtual Image:

#### Procedure

1. Select the pencil icon at the right of any row on the Virtual Images list page, or click EDIT on a Virtual Image detail page.
2. Configure the following on the Image: 

   Name
   :   Name of the Virtual Image in HPE Morpheus Enterprise. This can be changed from the name of the image, but editing will not change the name of the actual image

   Operating System
   :   Specifies the platform and OS of the image. All Windows images will need to have the operating system specified on the Virtual Image, as HPE Morpheus Enterprise will assign Linux as the platform for all images without an operating system specified

   Minimum Memory
   :   The Minimum Memory setting will filter available Service Plan options during provisioning. Service Plans that do not meet the minimum value set on the Virtual Image will not be provided as Service Plan choices

   Cloud Init Enabled?
   :   On by default, uncheck for any Image that does not have Cloud-Init or Cloudbase-Init installed

   Install Agent?
   :   On by default, uncheck to skip Agent install. Note this will result in the loss of utilization statistics, logs, script execution, and monitoring. (Some utilization stats are still collected for Agent-less hosts and VMs depending on the cloud)

   Username
   :   Existing username on the image. This is required for authentication, unless HPE Morpheus Enterprise is able to add user data, Cloud-Init, Cloudbase-Init or Guest Customizations. If Cloud-Init, Cloudbase-Init or Guest Customizations are used, credentials are defined in Administration > Settings > Provisioning and User Settings. If credentials are defined on the image and Cloud-Init is enabled, HPE Morpheus Enterprise will add that user during provisioning, so ensure that user does not already exist on the image (such as `root`). For Windows Guest Customizations, HPE Morpheus Enterprise will set the Administrator password to what is defined on the image if Administrator user is defined. Do not define any other user than Administrator for Windows Images unless using Cloudbase-init. HPE Morpheus Enterprise recommends running Guest Customizations for all Windows Images, which is required when joining Domains as the SID will change

   Password
   :   Password for the user on the image if username is populated

   Bucket
   :   Location where the Virtual Image will be stored. Default Virtual Image Storage location is `/var/opt/morpheus/morpheus-ui/vms`. Additional Storage Providers can be configured in Infrastructure  >  Storage

   Cloud-Init User Data
   :   Accepts what would go in `runcmd` and can assume Bash syntax. Example use: Script to configure satellite registration at provision time

   Create Image ID
   :   Select FILE to browse locally for an image or drop an image file into the dropzone. Alternatively, select URL to download the image from an accessible URL. It is recommend to configure the rest of the settings below prior to uploading the source Image File(s)

   Permissions
   :   Set Tenant permissions in a multi-tenant HPE Morpheus Enterprise environment. Select private visibility and select specific Tenants to which the Virtual Image will be made available. Select public visibility to share the Virtual Image with all Tenants

   Auto Join Domain?
   :   Enable to have Instances provisioned with this image auto-join configured domains (Windows only, domain controller must be configured in Infrastructure  >  Network and the configured domain set on the provisioned to Cloud or Network)

   VirtIO Drivers Loaded?
   :   Enable if VirtIO Drivers are installed on the image for provisioning to KVM-based hypervisors

   FIPS Compliant Image?
   :   When selected, HPE Morpheus Enterprise will install the FIPS-compliant HPE Morpheus Enterprise Agent package

   VM Tools Installed?
   :   On by default, uncheck if VMware Tools (including OpenVMTools) are not installed on the Virtual Image. HPE Morpheus Enterprise will skip network wait during provisioning when deselected

   Force Guest Customization?
   :   VMware only, forces guest customizations to run during provisioning, typically when provisioning to a DHCP network where guest customizations would not run by default. This options requires that VMware Tools is installed on the image

   Trial Version
   :   Enable to automatically re-arm the expiration on Windows Trial Images during provisioning

   Enabled Sysprep?
   :   Applicable to multiple Clouds, including VMware vCenter, SCVMM, Nutanix, Hyper-V, KVM, and Google GCP. Enable if the Windows Image has been sysprepped. If enabled, HPE Morpheus Enterprise will inject `unattend.xml`
3. Click Save Changes 

   NOTE

   Cloud-Init is enabled by default on all images. Images without Cloud-Init or Cloudbase-Init installed must have the `cloud-init` flag disabled on the Virtual Image setting or Provisioning may fail.

   IMPORTANT

   HPE Morpheus Enterprise does not validate or restrict image uploads to certain file types and any type of file may be uploaded as a Virtual Image. For security purposes, these files are stored in a non-executable state so users need not worry about potentially dangerous file types being uploaded (ex. executables).
