cloudera.cloud.ml module – Create or Destroy CDP Machine Learning Workspaces
Note
This module is part of the cloudera.cloud collection (version 2.5.1).
It is not included in ansible-core
.
To check whether it is installed, run ansible-galaxy collection list
.
To install it, use: ansible-galaxy collection install cloudera.cloud
.
You need further requirements to be able to use this module,
see Requirements for details.
To use it in a playbook, specify: cloudera.cloud.ml
.
Synopsis
Create or Destroy CDP Machine Learning Workspaces
Requirements
The below requirements are needed on the host that executes this module.
cdpy
Parameters
Parameter |
Comments |
---|---|
Specify the Cloudera Data Platform endpoint region. Default: |
|
Configuration for exporting model metrics to an existing Postgres database. |
|
The Postgres hostname |
|
The Postgres database name |
|
The Postgres password |
|
The Postgres port |
|
The Postgres user |
|
Capture the CDP SDK debug log. Choices:
|
|
The internal polling interval (in seconds) while the module waits for the ML Workspace to achieve the declared state. Default: |
|
The name of the Environment for the ML Workspace |
|
Flag to force delete a workspace even if errors occur during deletion. Force delete removes the guarantee that the cloud provider resources are destroyed. Applicable to Choices:
|
|
The flag to enable governance by integrating with Cloudera Atlas for the ML Workspace. Choices:
|
|
List of allowed CIDR blocks for the load balancer. |
|
Configuration for the Kubernetes provisioning of the ML Workspace. |
|
The Environment for the ML Workspace |
|
The instance groups for the ML Workspace provisioning request |
|
The autoscaling configuration for the instance group |
|
The flag enabling autoscaling Choices:
|
|
The maximum number of instances |
|
The minimum number of instances |
|
The networking rules for the ingress |
|
The initial number of instances Default: |
|
The provision tier of the instances. For example, |
|
The cloud provider instance type for the instance. For example, (AWS) |
|
A unique name of the instance group |
|
Configuration of the root volume for each instance |
|
The volume size (in GB) |
|
The overlay network for the Container Network Interface (CNI). AWS only. |
|
The identifier for the specific Container Network Interface (CNI) vendor For example, calico, weave. |
|
The options for overlay topology |
|
Configuration for the topology subnets |
|
Tags to add to the cloud provider resources |
|
The key/value pair for the tag |
|
The flag to enable the exporting of model metrics to a metrics store for the ML Workspace. Choices:
|
|
The flag to manage monitoring for the ML Workspace. Choices:
|
|
The name of the ML Workspace |
|
An existing NFS mount (hostname and desired path). Applicable to Azure and Private Cloud deployments only. |
|
The NFS Protocol version of the NFS server as declared in Applicable to Azure and Private Cloud deployments only. |
|
Flag to specify if a private K8s cluster should be created. Choices:
|
|
If provided, the CDP SDK will use this value as its profile. |
|
Flag to manage the usage of a public load balancer. Choices:
|
|
The declarative state of the ML Workspace Choices:
|
|
Flag to delete the ML Workspace backing storage during delete operations. Applicable to Choices:
|
|
The internal polling timeout (in seconds) while the module waits for the ML Workspace to achieve the declared state. Default: |
|
The flag to manage TLS for the ML Workspace. Choices:
|
|
Verify the TLS certificates for the CDP endpoint. Choices:
|
|
Flag to enable internal polling to wait for the ML Workspace to achieve the declared state. If set to FALSE, the module will return immediately. Choices:
|
Examples
# Note: These examples do not set authentication details.
# Create a ML Workspace with TLS turned off and wait for setup completion
- cloudera.cloud.ml:
name: ml-example
env: cdp-env
tls: no
wait: yes
# Create a ML Workspace (in AWS) with a custom Kubernetes request configuration
- cloudera.cloud.ml:
name: ml-k8s-example
env: cdp-env
k8s_request:
environmentName: cdp-env
instanceGroups:
- name: default_settings
autoscaling:
maxInstances: 10
minInstances: 1
instanceType: m5.2xlarge
- name: cpu_settings
autoscaling:
maxInstances: 10
minInstances: 1
instanceCount: 0
instanceTier: "ON_DEMAND"
instanceType: m5.2xlarge
rootVolume:
size: 60
- name: gpu_settings
autoscaling:
maxInstances: 1
minInstances: 0
instanceCount: 0
instanceTier: "ON_DEMAND"
instanceType: "p2.8xlarge"
rootVolume:
size: 40
wait: yes
# Remove a ML Workspace, but return immediately
- cloudera.cloud.ml:
name: ml-example
env: cdp-env
state: absent
wait: no
Return Values
Common return values are documented here, the following are the fields unique to this module:
Key |
Description |
---|---|
Returns the captured CDP SDK log. Returned: when supported |
|
Returns a list of each line of the captured CDP SDK log. Returned: when supported |
|
The information about the ML Workspace Returned: when supported |
|
The cloud platform of the environment that was used to create this workspace. Returned: always |
|
The basedomain of the cluster. Returned: when supported |
|
Creation date of workspace (date-time). Returned: always Sample: |
|
The CRN of the creator of the workspace. Returned: always |
|
The CRN of the workspace. Returned: always |
|
Flag indicating if the cluster is publicly accessible. Returned: always |
|
CRN of the environment. Returned: always |
|
The name of the workspace’s environment. Returned: always |
|
Failure message from the most recent failure that has occurred during workspace provisioning. Returned: during failure |
|
A filesystem ID referencing the filesystem that was created on the cloud provider environment that this workspace uses. Returned: always |
|
Flag indicating if Cloudera Atlas governance is enabled for the cluster. Returned: when supported |
|
The health info information of the workspace. Returned: success |
|
Healthinfo object contains the health information of a resource. Returned: always |
|
The detail of the health info. Returned: always |
|
The boolean that indicates the health status. Returned: always |
|
The message to show for the health info. Returned: always |
|
The resource name being checked. Returned: always |
|
The unix timestamp for the heartbeat. Returned: always |
|
Indicates if HTTPS communication was enabled on this workspace when provisioned. Returned: always |
|
The instance groups details for the cluster. Returned: always |
|
The initial number of instance nodes. Returned: always |
|
The unique name of the instance group. Returned: always |
|
Instances in the instance group. Returned: always |
|
Availability zone of the instance. Returned: always |
|
Unique instance Id generated by the cloud provider. Returned: always |
|
The cloud provider instance type for the node instances. Returned: always |
|
The maximum number of instances that can be deployed to this instance group. Returned: always |
|
The minimum number of instances that can be deployed to this instance group. If the value is 0, the group might be empty. Returned: always |
|
Key/value pairs applied to all applicable resources deployed in cloud provider. Returned: always |
|
Tag name Returned: always |
|
Tag value Returned: always |
|
The name of the workspace. Returned: always |
|
The workspace’s current status. Returned: always |
|
URL of the workspace’s user interface. Returned: always |
|
The Kubernetes cluster name. Returned: always |
|
The whitelist of ips for loadBalancer. Returned: always |
|
Flag indicating if model metrics export is enabled for the cluster. Returned: when supported |
|
If usage monitoring is enabled or not on this workspace. Returned: always |
|
Tags provided by the user at the time of workspace creation. Returned: always |
|
Tag name Returned: always |
|
Tag value Returned: always |
|
The version of Cloudera Machine Learning that was installed on the workspace. Returned: always |