Skip to content

OpsWorksServiceResource

Index > OpsWorks > OpsWorksServiceResource

Auto-generated documentation for OpsWorks type annotations stubs module mypy-boto3-opsworks.

OpsWorksServiceResource

Type annotations and code completion for boto3.resource("opsworks"), included resources and collections. boto3 documentation

Usage example
from mypy_boto3_opsworks.service_resource import OpsWorksServiceResource

def get_opsworks_resource() -> OpsWorksServiceResource:
    return boto3.resource("opsworks")

Attributes

Collections

ServiceResourceStacksCollection

Provides access to Stack resource.

Type annotations and code completion for boto3.resource("opsworks").stacks collection. boto3 documentation

Usage example
from mypy_boto3_opsworks.service_resource import ServiceResourceStacksCollection

def get_collection() -> ServiceResourceStacksCollection:
    return boto3.resource("opsworks").stacks

Methods

OpsWorksServiceResource.Layer method

Creates a Layer resource.

Type annotations and code completion for boto3.resource("opsworks").Layer method. boto3 documentation

Method definition
def Layer(
    self,
    id: str,
) -> Layer:
    ...
Usage example with kwargs
kwargs: ServiceResourceLayerRequestTypeDef = {  # (1)
    "id": ...,
}

parent.Layer(**kwargs)
  1. See ServiceResourceLayerRequestTypeDef

OpsWorksServiceResource.Stack method

Creates a Stack resource.

Type annotations and code completion for boto3.resource("opsworks").Stack method. boto3 documentation

Method definition
def Stack(
    self,
    id: str,
) -> Stack:
    ...
Usage example with kwargs
kwargs: ServiceResourceStackRequestTypeDef = {  # (1)
    "id": ...,
}

parent.Stack(**kwargs)
  1. See ServiceResourceStackRequestTypeDef

OpsWorksServiceResource.StackSummary method

Creates a StackSummary resource.

Type annotations and code completion for boto3.resource("opsworks").StackSummary method. boto3 documentation

Method definition
def StackSummary(
    self,
    stack_id: str,
) -> StackSummary:
    ...
Usage example with kwargs
kwargs: ServiceResourceStackSummaryRequestTypeDef = {  # (1)
    "stack_id": ...,
}

parent.StackSummary(**kwargs)
  1. See ServiceResourceStackSummaryRequestTypeDef

OpsWorksServiceResource.create_stack method

Creates a new stack.

Type annotations and code completion for boto3.resource("opsworks").create_stack method. boto3 documentation

Method definition
def create_stack(
    self,
    *,
    Name: str,
    Region: str,
    ServiceRoleArn: str,
    DefaultInstanceProfileArn: str,
    VpcId: str = ...,
    Attributes: Mapping[StackAttributesKeysType, str] = ...,  # (1)
    DefaultOs: str = ...,
    HostnameTheme: str = ...,
    DefaultAvailabilityZone: str = ...,
    DefaultSubnetId: str = ...,
    CustomJson: str = ...,
    ConfigurationManager: StackConfigurationManagerTypeDef = ...,  # (2)
    ChefConfiguration: ChefConfigurationTypeDef = ...,  # (3)
    UseCustomCookbooks: bool = ...,
    UseOpsworksSecurityGroups: bool = ...,
    CustomCookbooksSource: SourceTypeDef = ...,  # (4)
    DefaultSshKeyName: str = ...,
    DefaultRootDeviceType: RootDeviceTypeType = ...,  # (5)
    AgentVersion: str = ...,
) -> Stack:
    ...
  1. See StackAttributesKeysType
  2. See StackConfigurationManagerTypeDef
  3. See ChefConfigurationTypeDef
  4. See SourceTypeDef
  5. See RootDeviceTypeType
Usage example with kwargs
kwargs: CreateStackRequestServiceResourceCreateStackTypeDef = {  # (1)
    "Name": ...,
    "Region": ...,
    "ServiceRoleArn": ...,
    "DefaultInstanceProfileArn": ...,
}

parent.create_stack(**kwargs)
  1. See CreateStackRequestServiceResourceCreateStackTypeDef

OpsWorksServiceResource.get_available_subresources method

Returns a list of all the available sub-resources for this Resource.

Type annotations and code completion for boto3.resource("opsworks").get_available_subresources method. boto3 documentation

Method definition
def get_available_subresources(
    self,
) -> Sequence[str]:
    ...

Layer

Type annotations and code completion for boto3.resource("opsworks").Layer class. boto3 documentation

Usage example
from mypy_boto3_opsworks.service_resource import Layer

def get_resource() -> Layer:
    return boto3.resource("opsworks").Layer(...)

Layer attributes

Layer methods

Layer.delete method

Deletes a specified layer.

Type annotations and code completion for boto3.resource("opsworks").delete method. boto3 documentation

Method definition
def delete(
    self,
) -> None:
    ...

Layer.get_available_subresources method

Returns a list of all the available sub-resources for this Resource.

Type annotations and code completion for boto3.resource("opsworks").get_available_subresources method. boto3 documentation

Method definition
def get_available_subresources(
    self,
) -> Sequence[str]:
    ...

Layer.load method

Calls 🇵🇾meth:OpsWorks.Client.describe_layers to update the attributes of the Layer resource.

Type annotations and code completion for boto3.resource("opsworks").load method. boto3 documentation

Method definition
def load(
    self,
) -> None:
    ...

Layer.reload method

Calls 🇵🇾meth:OpsWorks.Client.describe_layers to update the attributes of the Layer resource.

Type annotations and code completion for boto3.resource("opsworks").reload method. boto3 documentation

Method definition
def reload(
    self,
) -> None:
    ...

Stack

Type annotations and code completion for boto3.resource("opsworks").Stack class. boto3 documentation

Usage example
from mypy_boto3_opsworks.service_resource import Stack

def get_resource() -> Stack:
    return boto3.resource("opsworks").Stack(...)

Stack attributes

Stack collections

Stack.layers

Provides access to Layer resource.

Type annotations and code completion for boto3.resource("opsworks").Stack(...).layers collection. boto3 documentation

Usage example
from mypy_boto3_opsworks.service_resource import StackLayersCollection

def get_collection() -> StackLayersCollection:
    resource = boto3.resource("opsworks").Stack(...)
    return resource.layers

Stack methods

Stack.Summary method

Creates a StackSummary resource.

Type annotations and code completion for boto3.resource("opsworks").Summary method. boto3 documentation

Method definition
def Summary(
    self,
) -> StackSummary:
    ...

Stack.create_layer method

Creates a layer.

Type annotations and code completion for boto3.resource("opsworks").create_layer method. boto3 documentation

Method definition
def create_layer(
    self,
    *,
    Type: LayerTypeType,  # (1)
    Name: str,
    Shortname: str,
    Attributes: Mapping[LayerAttributesKeysType, str] = ...,  # (2)
    CloudWatchLogsConfiguration: CloudWatchLogsConfigurationTypeDef = ...,  # (3)
    CustomInstanceProfileArn: str = ...,
    CustomJson: str = ...,
    CustomSecurityGroupIds: Sequence[str] = ...,
    Packages: Sequence[str] = ...,
    VolumeConfigurations: Sequence[VolumeConfigurationTypeDef] = ...,  # (4)
    EnableAutoHealing: bool = ...,
    AutoAssignElasticIps: bool = ...,
    AutoAssignPublicIps: bool = ...,
    CustomRecipes: RecipesTypeDef = ...,  # (5)
    InstallUpdatesOnBoot: bool = ...,
    UseEbsOptimizedInstances: bool = ...,
    LifecycleEventConfiguration: LifecycleEventConfigurationTypeDef = ...,  # (6)
) -> Layer:
    ...
  1. See LayerTypeType
  2. See LayerAttributesKeysType
  3. See CloudWatchLogsConfigurationTypeDef
  4. See VolumeConfigurationTypeDef
  5. See RecipesTypeDef
  6. See LifecycleEventConfigurationTypeDef
Usage example with kwargs
kwargs: CreateLayerRequestStackCreateLayerTypeDef = {  # (1)
    "Type": ...,
    "Name": ...,
    "Shortname": ...,
}

parent.create_layer(**kwargs)
  1. See CreateLayerRequestStackCreateLayerTypeDef

Stack.delete method

Deletes a specified stack.

Type annotations and code completion for boto3.resource("opsworks").delete method. boto3 documentation

Method definition
def delete(
    self,
) -> None:
    ...

Stack.get_available_subresources method

Returns a list of all the available sub-resources for this Resource.

Type annotations and code completion for boto3.resource("opsworks").get_available_subresources method. boto3 documentation

Method definition
def get_available_subresources(
    self,
) -> Sequence[str]:
    ...

Stack.load method

Calls 🇵🇾meth:OpsWorks.Client.describe_stacks to update the attributes of the Stack resource.

Type annotations and code completion for boto3.resource("opsworks").load method. boto3 documentation

Method definition
def load(
    self,
) -> None:
    ...

Stack.reload method

Calls 🇵🇾meth:OpsWorks.Client.describe_stacks to update the attributes of the Stack resource.

Type annotations and code completion for boto3.resource("opsworks").reload method. boto3 documentation

Method definition
def reload(
    self,
) -> None:
    ...

StackSummary

Type annotations and code completion for boto3.resource("opsworks").StackSummary class. boto3 documentation

Usage example
from mypy_boto3_opsworks.service_resource import StackSummary

def get_resource() -> StackSummary:
    return boto3.resource("opsworks").StackSummary(...)

StackSummary attributes

StackSummary methods

StackSummary.Stack method

Creates a Stack resource.

Type annotations and code completion for boto3.resource("opsworks").Stack method. boto3 documentation

Method definition
def Stack(
    self,
) -> Stack:
    ...

StackSummary.get_available_subresources method

Returns a list of all the available sub-resources for this Resource.

Type annotations and code completion for boto3.resource("opsworks").get_available_subresources method. boto3 documentation

Method definition
def get_available_subresources(
    self,
) -> Sequence[str]:
    ...

StackSummary.load method

Calls 🇵🇾meth:OpsWorks.Client.describe_stack_summary to update the attributes of the StackSummary resource.

Type annotations and code completion for boto3.resource("opsworks").load method. boto3 documentation

Method definition
def load(
    self,
) -> None:
    ...

StackSummary.reload method

Calls 🇵🇾meth:OpsWorks.Client.describe_stack_summary to update the attributes of the StackSummary resource.

Type annotations and code completion for boto3.resource("opsworks").reload method. boto3 documentation

Method definition
def reload(
    self,
) -> None:
    ...