azure.mgmt.resource.deploymentscripts.v2020_10_01.operations module

class azure.mgmt.resource.deploymentscripts.v2020_10_01.operations.DeploymentScriptsOperations(*args, **kwargs)[source]

Bases: object

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through DeploymentScriptsClient’s deployment_scripts attribute.

begin_create(resource_group_name: str, script_name: str, deployment_script: _models.DeploymentScript, *, content_type: str = 'application/json', **kwargs: Any) LROPoller[_models.DeploymentScript][source]
begin_create(resource_group_name: str, script_name: str, deployment_script: IO[bytes], *, content_type: str = 'application/json', **kwargs: Any) LROPoller[_models.DeploymentScript]

Creates a deployment script.

Parameters:
  • resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.

  • script_name (str) – Name of the deployment script. Required.

  • deployment_script (DeploymentScript or IO[bytes]) – Deployment script supplied to the operation. Is either a DeploymentScript type or a IO[bytes] type. Required.

Returns:

An instance of LROPoller that returns either DeploymentScript or the result of cls(response)

Return type:

LROPoller[DeploymentScript]

Raises:

HttpResponseError

delete(resource_group_name: str, script_name: str, **kwargs: Any) None[source]

Deletes a deployment script. When operation completes, status code 200 returned without content.

Parameters:
  • resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.

  • script_name (str) – Name of the deployment script. Required.

Returns:

None or the result of cls(response)

Return type:

None

Raises:

HttpResponseError

get(resource_group_name: str, script_name: str, **kwargs: Any) DeploymentScript[source]

Gets a deployment script with a given name.

Parameters:
  • resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.

  • script_name (str) – Name of the deployment script. Required.

Returns:

DeploymentScript or the result of cls(response)

Return type:

DeploymentScript

Raises:

HttpResponseError

get_logs(resource_group_name: str, script_name: str, **kwargs: Any) ScriptLogsList[source]

Gets deployment script logs for a given deployment script name.

Parameters:
  • resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.

  • script_name (str) – Name of the deployment script. Required.

Returns:

ScriptLogsList or the result of cls(response)

Return type:

ScriptLogsList

Raises:

HttpResponseError

get_logs_default(resource_group_name: str, script_name: str, tail: int | None = None, **kwargs: Any) ScriptLog[source]

Gets deployment script logs for a given deployment script name.

Parameters:
  • resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.

  • script_name (str) – Name of the deployment script. Required.

  • tail (int) – The number of lines to show from the tail of the deployment script log. Valid value is a positive number up to 1000. If ‘tail’ is not provided, all available logs are shown up to container instance log capacity of 4mb. Default value is None.

Returns:

ScriptLog or the result of cls(response)

Return type:

ScriptLog

Raises:

HttpResponseError

list_by_resource_group(resource_group_name: str, **kwargs: Any) Iterable[DeploymentScript][source]

Lists deployments scripts.

Parameters:

resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.

Returns:

An iterator like instance of either DeploymentScript or the result of cls(response)

Return type:

ItemPaged[DeploymentScript]

Raises:

HttpResponseError

list_by_subscription(**kwargs: Any) Iterable[DeploymentScript][source]

Lists all deployment scripts for a given subscription.

Returns:

An iterator like instance of either DeploymentScript or the result of cls(response)

Return type:

ItemPaged[DeploymentScript]

Raises:

HttpResponseError

update(resource_group_name: str, script_name: str, deployment_script: _models.DeploymentScriptUpdateParameter | None = None, *, content_type: str = 'application/json', **kwargs: Any) _models.DeploymentScript[source]
update(resource_group_name: str, script_name: str, deployment_script: IO[bytes] | None = None, *, content_type: str = 'application/json', **kwargs: Any) _models.DeploymentScript

Updates deployment script tags with specified values.

Parameters:
  • resource_group_name (str) – The name of the resource group. The name is case insensitive. Required.

  • script_name (str) – Name of the deployment script. Required.

  • deployment_script (DeploymentScriptUpdateParameter or IO[bytes]) – Deployment script resource with the tags to be updated. Is either a DeploymentScriptUpdateParameter type or a IO[bytes] type. Default value is None.

Returns:

DeploymentScript or the result of cls(response)

Return type:

DeploymentScript

Raises:

HttpResponseError

models = <module 'azure.mgmt.resource.deploymentscripts.v2020_10_01.models' from '/mnt/vss/_work/1/s/sdk/resources/azure-mgmt-resource/.tox/sphinx/lib/python3.11/site-packages/azure/mgmt/resource/deploymentscripts/v2020_10_01/models/__init__.py'>