psm dhcs create-service

Create an Oracle Data Hub Cloud Service cluster.

Syntax

In the following syntax, line breaks have been added for clarity. Do not include them when entering the command.

psm dhcs create-service -c|--config-payload path-to-json-file
	[-of|--output-format short|json|html]
	[-wc|--wait-until-complete true|false]

Parameters

Parameter Description

-c|--config-payload path-to-json-file

Specifies the path to a JSON file containing the information necessary to create a cluster. The format of this file is the same as the request body you provide when creating a service instance by using the REST API. For information about this format, see the “Body Parameter” section of Create a Service Instance in REST API for Oracle Data Hub Cloud Service.

-of|--output-format short|json|html

(Optional) Specifies the output format of the command’s response:

  • short— output is formatted as a brief summary.

  • json— output is formatted as a JSON array.

  • html— output is formatted as HTML

The default output format is the one you specified when using the psm setup command to configure the psm CLI.

–wc|--wait-until-complete true|false

(Optional) If set to true, the command behaves synchronously. That is, it does not return until the submitted job is complete. The following message is displayed until the job is complete:

Waiting for the job to complete... (it cannot be cancelled)

The default value is false.

Examples

The following example creates an Oracle Data Hub Cloud Service cluster as specified by information provided in the create_cluster1.json file.

$ psm dhcs create-service --config-payload create_cluster1.json
{
    "details":{
        "message":"Submitted job to create service [cluster1] in domain [beta].",
        "jobId":"7123184"
    }
}
Job ID : 7123184

Note:

You can track the progress of this command by using the psm dhcs operation-status command.

Listing of create_cluster1.json

Note that the value of vmPublicKeyText has been truncated in the following listing.

{
    "vmPublicKeyText":"ssh-rsa AAAAB3...",
    "backupDestination":"BOTH",
    "cloudStorageContainer":"http://example.storage.oraclecloud.com/Storage-example/DHCS",
    "cloudStorageUser":"StorageAdmin",
    "cloudStoragePassword":"password",
    "cloudStorageContainerAutoGenerate":false,
    "useHighPerformanceStorage":false,
    "serviceName":"cluster1",
    "serviceDescription":"Demo cluster",
    "serviceLevel":"PAAS",
    "meteringFrequency":"HOURLY" ,
    "serviceVersion":"3.11.1",
    "edition":"EE",
    "vmUser":"opc",                 
    "enableNotification":false,    
    "isBYOL":false,
    "components":{
        "CASSANDRA":{
            "shape":"oc1m",
            "serverCount":"2",
            "dataStorage":"50",
            "adminUserName":"admin",
            "adminUserPassword":"password"
        }
    }
}