RunObjectStoreScriptUserDefinedStep

class oci.disaster_recovery.models.RunObjectStoreScriptUserDefinedStep(**kwargs)

Bases: DrPlanUserDefinedStep

Run Object Store Script step details.

Attributes:

STEP_TYPE_INVOKE_FUNCTION

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_INVOKE_FUNCTION_PRECHECK

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_INVOKE_FUNCTION_USER_DEFINED_CUSTOM_PRECHECK

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_RUN_LOCAL_SCRIPT

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_RUN_LOCAL_SCRIPT_PRECHECK

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_RUN_LOCAL_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_RUN_OBJECTSTORE_SCRIPT

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_RUN_OBJECTSTORE_SCRIPT_PRECHECK

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

STEP_TYPE_RUN_OBJECTSTORE_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK

A constant which can be used with the step_type property of a DrPlanUserDefinedStep.

object_storage_script_location

[Required] Gets the object_storage_script_location of this RunObjectStoreScriptUserDefinedStep.

run_as_user

Gets the run_as_user of this RunObjectStoreScriptUserDefinedStep.

run_on_instance_id

[Required] Gets the run_on_instance_id of this RunObjectStoreScriptUserDefinedStep.

run_on_instance_region

[Required] Gets the run_on_instance_region of this RunObjectStoreScriptUserDefinedStep.

script_command

Gets the script_command of this RunObjectStoreScriptUserDefinedStep.

step_type

[Required] Gets the step_type of this DrPlanUserDefinedStep.

Methods:

__init__(**kwargs)

Initializes a new RunObjectStoreScriptUserDefinedStep object with values from keyword arguments.

get_subtype(object_dictionary)

Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.

STEP_TYPE_INVOKE_FUNCTION = 'INVOKE_FUNCTION'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “INVOKE_FUNCTION”

STEP_TYPE_INVOKE_FUNCTION_PRECHECK = 'INVOKE_FUNCTION_PRECHECK'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “INVOKE_FUNCTION_PRECHECK”

STEP_TYPE_INVOKE_FUNCTION_USER_DEFINED_CUSTOM_PRECHECK = 'INVOKE_FUNCTION_USER_DEFINED_CUSTOM_PRECHECK'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “INVOKE_FUNCTION_USER_DEFINED_CUSTOM_PRECHECK”

STEP_TYPE_RUN_LOCAL_SCRIPT = 'RUN_LOCAL_SCRIPT'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “RUN_LOCAL_SCRIPT”

STEP_TYPE_RUN_LOCAL_SCRIPT_PRECHECK = 'RUN_LOCAL_SCRIPT_PRECHECK'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “RUN_LOCAL_SCRIPT_PRECHECK”

STEP_TYPE_RUN_LOCAL_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK = 'RUN_LOCAL_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “RUN_LOCAL_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK”

STEP_TYPE_RUN_OBJECTSTORE_SCRIPT = 'RUN_OBJECTSTORE_SCRIPT'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “RUN_OBJECTSTORE_SCRIPT”

STEP_TYPE_RUN_OBJECTSTORE_SCRIPT_PRECHECK = 'RUN_OBJECTSTORE_SCRIPT_PRECHECK'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “RUN_OBJECTSTORE_SCRIPT_PRECHECK”

STEP_TYPE_RUN_OBJECTSTORE_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK = 'RUN_OBJECTSTORE_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK'

A constant which can be used with the step_type property of a DrPlanUserDefinedStep. This constant has a value of “RUN_OBJECTSTORE_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK”

__init__(**kwargs)

Initializes a new RunObjectStoreScriptUserDefinedStep object with values from keyword arguments. The default value of the step_type attribute of this class is RUN_OBJECTSTORE_SCRIPT and it should not be changed. The following keyword arguments are supported (corresponding to the getters/setters of this class):

Parameters
  • step_type (str) – The value to assign to the step_type property of this RunObjectStoreScriptUserDefinedStep. Allowed values for this property are: “RUN_OBJECTSTORE_SCRIPT_PRECHECK”, “RUN_LOCAL_SCRIPT_PRECHECK”, “INVOKE_FUNCTION_PRECHECK”, “RUN_OBJECTSTORE_SCRIPT”, “RUN_LOCAL_SCRIPT”, “INVOKE_FUNCTION”, “RUN_OBJECTSTORE_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK”, “RUN_LOCAL_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK”, “INVOKE_FUNCTION_USER_DEFINED_CUSTOM_PRECHECK”

  • run_on_instance_id (str) – The value to assign to the run_on_instance_id property of this RunObjectStoreScriptUserDefinedStep.

  • run_on_instance_region (str) – The value to assign to the run_on_instance_region property of this RunObjectStoreScriptUserDefinedStep.

  • object_storage_script_location (oci.disaster_recovery.models.ObjectStorageScriptLocation) – The value to assign to the object_storage_script_location property of this RunObjectStoreScriptUserDefinedStep.

  • script_command (str) – The value to assign to the script_command property of this RunObjectStoreScriptUserDefinedStep.

  • run_as_user (str) – The value to assign to the run_as_user property of this RunObjectStoreScriptUserDefinedStep.

static get_subtype(object_dictionary)

Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype.

property object_storage_script_location

[Required] Gets the object_storage_script_location of this RunObjectStoreScriptUserDefinedStep.

Returns

The object_storage_script_location of this RunObjectStoreScriptUserDefinedStep.

Return type

oci.disaster_recovery.models.ObjectStorageScriptLocation

property run_as_user

Gets the run_as_user of this RunObjectStoreScriptUserDefinedStep. The user ID on the instance that will be used to execute the script specified in ‘scriptCommand’.

Example: opc

Returns

The run_as_user of this RunObjectStoreScriptUserDefinedStep.

Return type

str

property run_on_instance_id

[Required] Gets the run_on_instance_id of this RunObjectStoreScriptUserDefinedStep. The OCID of the instance on which this script or command should be executed.

For moving instances: runOnInstanceId must be the OCID of the instance in the region where the instance is currently present.

For non-moving instances: runOnInstanceId must be the OCID of the non-moving instance.

Example: ocid1.instance.oc1..uniqueID

Returns

The run_on_instance_id of this RunObjectStoreScriptUserDefinedStep.

Return type

str

property run_on_instance_region

[Required] Gets the run_on_instance_region of this RunObjectStoreScriptUserDefinedStep. The region of the instance where this script or command should be executed.

Example: us-ashburn-1

Returns

The run_on_instance_region of this RunObjectStoreScriptUserDefinedStep.

Return type

str

property script_command

Gets the script_command of this RunObjectStoreScriptUserDefinedStep. The entire path and arguments for the script that is stored in object store, or inside a compressed archive in object store.

Example: /usr/bin/python3.7 scripts/start_server.py –port 8080 –env “production” –max-connections 200 –log-level “INFO”

Returns

The script_command of this RunObjectStoreScriptUserDefinedStep.

Return type

str

property step_type

[Required] Gets the step_type of this DrPlanUserDefinedStep. The type of the user-defined step.

RUN_OBJECTSTORE_SCRIPT_PRECHECK - A built-in step which performs a precheck on a script stored

in OCI object storage. This step cannot be added, deleted, or customized by the user.

RUN_LOCAL_SCRIPT_PRECHECK - A built-in step which performs a precheck on a script which resides

locally on a compute instance. This step cannot be added, deleted, or customized by the user.

INVOKE_FUNCTION_PRECHECK - A built-in step which performs a precheck on an OCI function. This

step cannot be added, deleted, or customized by the user. See https://docs.oracle.com/en-us/iaas/Content/Functions/home.htm.

RUN_OBJECTSTORE_SCRIPT - A step which runs a script stored in OCI object storage.

RUN_LOCAL_SCRIPT - A step which runs a script that resides locally on a compute instance.

INVOKE_FUNCTION - A step which invokes an OCI function.

See https://docs.oracle.com/en-us/iaas/Content/Functions/home.htm.

RUN_OBJECTSTORE_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK - A user-defined step which performs a precheck by executing a user-provided script stored

in OCI object storage.

RUN_LOCAL_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK - A user-defined step which performs a precheck by executing a user-provided script which resides

locally on a compute instance.

INVOKE_FUNCTION_USER_DEFINED_CUSTOM_PRECHECK - A user-defined step which performs a precheck by executing a user-provided OCI function.

See https://docs.oracle.com/en-us/iaas/Content/Functions/home.htm.

Allowed values for this property are: “RUN_OBJECTSTORE_SCRIPT_PRECHECK”, “RUN_LOCAL_SCRIPT_PRECHECK”, “INVOKE_FUNCTION_PRECHECK”, “RUN_OBJECTSTORE_SCRIPT”, “RUN_LOCAL_SCRIPT”, “INVOKE_FUNCTION”, “RUN_OBJECTSTORE_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK”, “RUN_LOCAL_SCRIPT_USER_DEFINED_CUSTOM_PRECHECK”, “INVOKE_FUNCTION_USER_DEFINED_CUSTOM_PRECHECK”, ‘UNKNOWN_ENUM_VALUE’. Any unrecognized values returned by a service will be mapped to ‘UNKNOWN_ENUM_VALUE’.

Returns

The step_type of this DrPlanUserDefinedStep.

Return type

str