ml deployment update
Update the deployment metadata.
Syntax
cpd-cli ml deployment update \
[--asset=<resource-reference>] \
[--context=<catalog-project-or-space-id>] \
[--cpd-config=<cpd-config-location>] \
[--cpd-scope=<cpd-scope>] \
[--custom=<map<key,value>>] \
--deployment-id=<deployment-id-or-serving-name> \
[--description=<deployment-description>] \
[--hardware-spec=<hardware-specification>] \
[--hybrid-pipeline-hardware-specs=<hybrid-pipeline-hardware-specification>] \
[--jmes-query=<jmespath-query>] \
--json-patch=<json-array> \
[--name=<deployment-name>] \
[--output=json|yaml|table] \
[--output-file=<output-file-location>] \
--profile=<cpd-profile-name> \
[--quiet] \
[--r-shiny] \
[--raw-output=true|false] \
--space-id=<space-identifier> \
[--tags=<tag1,tag2,...>] \
[--verbose]
Arguments
The ml deployment update
command
has no arguments.
Options
Table 1: Command options
Option | Description |
---|---|
--asset |
Specify a resource
reference.
|
--async |
Run the command asynchronously. By
default, processing finishes before the command runs.
|
--batch |
Specify an empty object. The
option indicates a batch deployment. More properties can be added later when setting up the batch
deployment.
|
--context |
Specify the configuration context
name.
|
--cpd-config |
The Cloud Pak for Data
configuration location. For example,
$HOME/.cpd-cli/config.
|
--cpd-scope |
The Cloud Pak for Data space, project, or catalog scope. For example, cpd://default-context/spaces/7bccdda4-9752-4f37-868e-891de6c48135.
|
--custom |
Specify user-defined properties as
key-value pairs.
|
--description |
Specify a deployment
description.
|
--hardware-spec |
Specify a hardware
specification.
|
|
Display command
help.
|
--hybrid-pipeline-hardware-specs |
Specify a hybrid pipeline hardware
specification.
|
--jmes-query |
Provide a JMESPath query to
customize the output.
|
--name |
Specify a deployment
name.
|
--online |
Specify an empty object. The
option indicates an online deployment. More properties can be added later during online deployment
setup. The 'serving_name' can be provided in the 'online.parameters'. The 'serving_name' can include
only the characters [a-z,0-9,_] and the length cannot exceed 36 characters. The 'serving_name' can
be used in the prediction URL in place of the
'deployment_id'.
|
--output |
Specify an output
format.
|
--output-file |
Specify a file path where all
output is redirected.
|
--profile |
The name of the profile that you
created to store information about an instance of Cloud Pak for Data and your credentials for the
instance.
|
--quiet |
Suppress verbose
messages.
|
--r-shiny |
Indicates a Shiny application
deployment.
|
--raw-output |
When set to true, single values
are not surrounded by quotation marks in
JSON output
mode.
|
--space-id |
Specify a space
identifier.
|
--tags |
Specify the data asset tags.
Multiple tags can be specified.
|
--verbose |
Logs include more detailed
messages.
|
Examples
Note: The following examples use environment variables. Use a script to create
environment variables with the correct values for your environment. You can add the listed
environment variables to the installation variables script. For more information, see Setting up installation environment variables.
- Specify the environment variables in a script file.
-
asset = { 'id': prod_script_id } asset_json = json.dumps(asset) deployment_name = 'script_batch_deployment' space_id = <The deployment space identifier>
- Update a deployed asset with a new script.
-
cpd-cli ml deployment update \ --asset=${asset_json} \ --deployment-id=${deployment_name} \ --space-id=${space_id}
- Example results.
-
ID: 25e17b86-9deb-4950-920d-47ba1fc781c1 Name: script_batch_deployment Created: 2021-04-30T12:39:28.441Z State: ready Tags: []