Package com.morpheusdata.core.providers
Interface ProvisionProvider
- All Superinterfaces:
PluginProvider
- All Known Subinterfaces:
CloudNativeProvisionProvider
,ComputeProvisionProvider
,HostProvisionProvider
,ProvisionProvider
,ResourceProvisionProvider
,VmProvisionProvider
,WorkloadProvisionProvider
- All Known Implementing Classes:
AbstractProvisionProvider
Provides methods for interacting with the provisioning engine of Morpheus. This is akin to dealing with requests made
from "Add Instance" or from Application Blueprints
- Since:
- 0.8.0
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic interface
Provides a method to allow a provision provider to override the array list of disk device names.static interface
Provides methods for interacting with provisioned vms through a hypervisor consolestatic interface
Provides methods for provisioning hypervisorsstatic interface
Provides methods for supporting Infrastructure as Code provisioningstatic interface
Provides methods for interacting with provisioned vms to manage associated snapshots -
Method Summary
Modifier and TypeMethodDescriptiondefault Boolean
Can control firewall rules on the instancedefault Boolean
Indicates if volumes may be added during provisioningdefault Boolean
Indicates if data volumes may be customized during provisioning.default Boolean
Indicates if the root volume may be customized during provisioning.default Boolean
Indicates if the network can be changeddefault Boolean
Indicates if the root volume may be resizeddefault ServiceResponse
cloneToTemplate
(Workload workload, Map opts) Used to create a new template or image from a given VM if the cloud supports doing sodefault Boolean
Indicates if a ComputeZonePool is required during provisioningdefault Boolean
For most provision types, a default instance type is created upon plugin registration.default Boolean
Indicates if this provider supports custom layoutsdefault Boolean
Indicates if a Datastore on a root volume on a ComputeServer is configurabledefault Icon
Provide an icon to be displayed for ServicePlans, VM detail page, etc.default Collection<ComputeServerInterfaceType>
Provides a Collection ofComputeServerInterfaceType
related to this ProvisionProviderdefault Collection<ComputeTypeLayout>
Provides a Collection ofComputeTypeLayout
related to this ProvisionProvider.default Collection<StorageVolumeType>
Provides a Collection of StorageVolumeTypes that are available for data StorageVolumesdefault String
If your provision type creates a default instance type, implement this method to provide a description for the default instance type which will appear in the morpheus provision wizard.default ArrayList<OptionType>
Implement this method if you need specific option types for the default instance type for this provision provider.default String
The name of the deployment service for this provider valid options include: vmDeployTargetService, dockerDeployTargetService, kubernetesDeployTargetService, and cloudFoundryDeployTargetServicedefault String
default HostType
Returns the host type that is to be provisioneddefault Integer
Returns the maximum number of network interfaces that can be chosen when provisioning with this typedefault String
The node format for this provider valid options are: vm, server, containerdefault Collection<OptionType>
Provides a Collection of OptionType inputs for configuring node typesdefault Collection<OptionType>
Provides a Collection of OptionType inputs that need to be made available to various provisioning Wizardsdefault String
Some older clouds have a provision type code that is the exact same as the cloud code.default Collection<StorageVolumeType>
Provides a Collection of StorageVolumeTypes that are available for root StorageVolumesdefault Collection<ServicePlan>
Provides a Collection of $ServicePlan
related to this ProvisionProvider that can be seeded in.default Collection<TemplateParameter>
getTemplateParameters
(ResourceSpecTemplate template, String fileContent, Map opts) Provides a Collection of TemplateParameter to describe the options for the ResourceSpecTemplate for this ProvisionProviderdefault String
Used to retrieve if the provision provider uses a NON standard set of views to render part of the provisioning wizarddefault Collection<VirtualImage>
Provides a Collection ofVirtualImage
related to this ProvisionProvider.default Collection<VirtualImageType>
Provides a Collection ofVirtualImageType
compatible to this ProvisionProvider.default Boolean
Indicates if this provider supports cloning a vm to a templatedefault Boolean
Determines if this provision type has ComputeZonePools that can be selected or not.default Boolean
Indicates if the sockets are configurable when deploying a ComputeServer via a custom plandefault Boolean
Determines if this provision type has datastores that can be selected or not.default Boolean
Determines if this provision type has networks that can be selected or not.default Boolean
Indicates if this provider supports node typesdefault Boolean
Determines if this provision type supports service plans that expose the tag match property.default Boolean
Can control security groups for instances using this provision providerdefault Boolean
Indicates if StorageControllers are utilizeddefault Boolean
Indicates if this provider supports LVM instancesdefault Boolean
Does this provision type allow more than one instance on a boxdefault Boolean
Indicates if Network selection should be scoped to the ComputeZonePool selected during provisioningdefault Boolean
By default, provision providers require a virtual image (ami, ovf/vmdk, etc) in order to provision an instance.default String
Indicates if this provider should set a server type different from its code, e.g.default Boolean
Override this method to return false if its a provision type that does not support the morpheus agent install.default Boolean
Indicates if automatic Datastore selection is supporteddefault Boolean
Custom service plans can be created for this providerMethods inherited from interface com.morpheusdata.core.providers.PluginProvider
getCode, getMorpheus, getName, getPlugin, isPlugin
-
Method Details
-
getProvisionTypeCode
Some older clouds have a provision type code that is the exact same as the cloud code. This allows one to set it to match and in doing so the provider will be fetched via the cloud providersCloudProvider.getDefaultProvisionTypeCode()
method.- Returns:
- code for overriding the ProvisionType record code property
-
getCircularIcon
Provide an icon to be displayed for ServicePlans, VM detail page, etc. where a circular icon is displayed- Returns:
- Icon
- Since:
- 0.13.6
-
getOptionTypes
Provides a Collection of OptionType inputs that need to be made available to various provisioning Wizards- Returns:
- Collection of OptionTypes
-
getNodeOptionTypes
Provides a Collection of OptionType inputs for configuring node types- Returns:
- Collection of OptionTypes
- Since:
- 0.9.0
-
getRootVolumeStorageTypes
Provides a Collection of StorageVolumeTypes that are available for root StorageVolumes- Returns:
- Collection of StorageVolumeTypes
-
getDataVolumeStorageTypes
Provides a Collection of StorageVolumeTypes that are available for data StorageVolumes- Returns:
- Collection of StorageVolumeTypes
-
getServicePlans
Provides a Collection of $ServicePlan
related to this ProvisionProvider that can be seeded in. Some clouds do not use this as they may be synced in from the public cloud. This is more of a factor for On-Prem clouds that may wish to have some precanned plans provided for it.- Returns:
- Collection of ServicePlan sizes that can be seeded in at plugin startup.
-
getComputeServerInterfaceTypes
Provides a Collection ofComputeServerInterfaceType
related to this ProvisionProvider- Returns:
- Collection of ComputeServerInterfaceType
-
getTemplateParameters
default Collection<TemplateParameter> getTemplateParameters(ResourceSpecTemplate template, String fileContent, Map opts) Provides a Collection of TemplateParameter to describe the options for the ResourceSpecTemplate for this ProvisionProvider- Parameters:
template
- The ResourceSpecTemplatefileContent
- The file content of the templateopts
- Additional options- Returns:
- Collection of TemplateParameter objects to describe the options for the ResourceSpecTemplate
- Since:
- 0.15.4
-
hasDatastores
Determines if this provision type has datastores that can be selected or not.- Returns:
- Boolean representation of whether or not this provision type has datastores
-
hasNetworks
Determines if this provision type has networks that can be selected or not.- Returns:
- Boolean representation of whether or not this provision type has networks
-
hasPlanTagMatch
Determines if this provision type supports service plans that expose the tag match property.- Returns:
- Boolean representation of whether or not service plans expose the tag match property.
-
hasComputeZonePools
Determines if this provision type has ComputeZonePools that can be selected or not.- Returns:
- Boolean representation of whether or not this provision type has ComputeZonePools
-
computeZonePoolRequired
Indicates if a ComputeZonePool is required during provisioning- Returns:
- Boolean
-
canAddVolumes
Indicates if volumes may be added during provisioning- Returns:
- Boolean
-
canCustomizeRootVolume
Indicates if the root volume may be customized during provisioning. For example, the size changed- Returns:
- Boolean
-
disableRootDatastore
Indicates if a Datastore on a root volume on a ComputeServer is configurable- Returns:
- Boolean
-
hasConfigurableSockets
Indicates if the sockets are configurable when deploying a ComputeServer via a custom plan- Returns:
- Boolean
-
supportsCustomServicePlans
Custom service plans can be created for this provider- Returns:
- Boolean
-
hasNodeTypes
Indicates if this provider supports node types- Returns:
- Boolean
-
getNodeFormat
The node format for this provider valid options are: vm, server, container- Returns:
- String
-
getDeployTargetService
The name of the deployment service for this provider valid options include: vmDeployTargetService, dockerDeployTargetService, kubernetesDeployTargetService, and cloudFoundryDeployTargetService- Returns:
- String
-
hasCloneTemplate
Indicates if this provider supports cloning a vm to a template- Returns:
- Boolean
-
cloneToTemplate
Used to create a new template or image from a given VM if the cloud supports doing so- Parameters:
workload
- The workload to use as the reference for the templateopts
- Additional settings, including templateName- Returns:
- ServiceResponse indicates success or failure along with any messages
-
customSupported
Indicates if this provider supports custom layouts- Returns:
- Boolean
-
lvmSupported
Indicates if this provider supports LVM instances- Returns:
- Boolean
-
serverType
Indicates if this provider should set a server type different from its code, e.g. "service" or "vm"- Returns:
- String
-
getViewSet
Used to retrieve if the provision provider uses a NON standard set of views to render part of the provisioning wizard- Returns:
- String
-
requiresVirtualImage
By default, provision providers require a virtual image (ami, ovf/vmdk, etc) in order to provision an instance. However, some service based instance types do not require a virtual image (Amazon RDS for example)- Returns:
- Boolean
-
supportsAgent
Override this method to return false if its a provision type that does not support the morpheus agent install. This will be the case for provision types of non standard operating systems or service based provision types (Amazon RDS for example)- Returns:
-
createDefaultInstanceType
For most provision types, a default instance type is created upon plugin registration. Override this method if you do NOT want to create a default instance type for your provision provider- Returns:
- defaults to true
-
getDefaultInstanceTypeDescription
If your provision type creates a default instance type, implement this method to provide a description for the default instance type which will appear in the morpheus provision wizard.- Returns:
- a String detailing the use of the ProvisionProvider default instance type
-
getDefaultInstanceTypeOptions
Implement this method if you need specific option types for the default instance type for this provision provider. For example, image/template selection.- Returns:
- a collection of
OptionType
-
multiTenant
Does this provision type allow more than one instance on a box- Returns:
-
aclEnabled
Can control firewall rules on the instance- Returns:
-
getHostDiskMode
-
hasSecurityGroups
Can control security groups for instances using this provision provider- Returns:
-
canCustomizeDataVolumes
Indicates if data volumes may be customized during provisioning. For example, the size changed- Returns:
- Boolean
-
canResizeRootVolume
Indicates if the root volume may be resized- Returns:
- Boolean
-
canReconfigureNetwork
Indicates if the network can be changed- Returns:
- Boolean
-
hasStorageControllers
Indicates if StorageControllers are utilized- Returns:
- Boolean
-
supportsAutoDatastore
Indicates if automatic Datastore selection is supported- Returns:
- Boolean
-
networksScopedToPools
Indicates if Network selection should be scoped to the ComputeZonePool selected during provisioning- Returns:
- Boolean
-
getMaxNetworks
Returns the maximum number of network interfaces that can be chosen when provisioning with this type- Returns:
- maximum number of networks or 0,null if unlimited.
-
getHostType
Returns the host type that is to be provisioned- Returns:
- HostType
-
getVirtualImages
Provides a Collection ofVirtualImage
related to this ProvisionProvider. This provides a way to specify known VirtualImages in the Cloud environment prior to a typical 'refresh' on a Cloud. These are often used in predefined layouts. For example, when building up ComputeTypeLayouts via theMorpheusComputeTypeLayoutFactoryService
- Returns:
- Collection of
VirtualImage
-
getVirtualImageTypes
Provides a Collection ofVirtualImageType
compatible to this ProvisionProvider. The list of compatible virtual image types (raw, iso, qcow2) are used to determine which virtual images are compatible with this cloud. A common use for virtual image types is filtering list of virtual images during the creation of a workload.- Returns:
- Collection of
VirtualImageType
-
getComputeTypeLayouts
Provides a Collection ofComputeTypeLayout
related to this ProvisionProvider. These define the types of clusters that are exposed for this ProvisionProvider. ComputeTypeLayouts have a collection of ComputeTypeSets, which reference a ContainerType. When returning this structure from implementations, it is often helpful to start with the ComputeTypeLayoutFactory to construct the default structure and modify fields as needed.- Returns:
- Collection of ComputeTypeLayout
-