CfnServicePropsMixin

class aws_cdk.mixins_preview.aws_apprunner.mixins.CfnServicePropsMixin(props, *, strategy=None)

Bases: Mixin

Specify an AWS App Runner service by using the AWS::AppRunner::Service resource in an AWS CloudFormation template.

The AWS::AppRunner::Service resource is an AWS App Runner resource type that specifies an App Runner service.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-apprunner-service.html

CloudformationResource:

AWS::AppRunner::Service

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

cfn_service_props_mixin = apprunner_mixins.CfnServicePropsMixin(apprunner_mixins.CfnServiceMixinProps(
    auto_scaling_configuration_arn="autoScalingConfigurationArn",
    encryption_configuration=apprunner_mixins.CfnServicePropsMixin.EncryptionConfigurationProperty(
        kms_key="kmsKey"
    ),
    health_check_configuration=apprunner_mixins.CfnServicePropsMixin.HealthCheckConfigurationProperty(
        healthy_threshold=123,
        interval=123,
        path="path",
        protocol="protocol",
        timeout=123,
        unhealthy_threshold=123
    ),
    instance_configuration=apprunner_mixins.CfnServicePropsMixin.InstanceConfigurationProperty(
        cpu="cpu",
        instance_role_arn="instanceRoleArn",
        memory="memory"
    ),
    network_configuration=apprunner_mixins.CfnServicePropsMixin.NetworkConfigurationProperty(
        egress_configuration=apprunner_mixins.CfnServicePropsMixin.EgressConfigurationProperty(
            egress_type="egressType",
            vpc_connector_arn="vpcConnectorArn"
        ),
        ingress_configuration=apprunner_mixins.CfnServicePropsMixin.IngressConfigurationProperty(
            is_publicly_accessible=False
        ),
        ip_address_type="ipAddressType"
    ),
    observability_configuration=apprunner_mixins.CfnServicePropsMixin.ServiceObservabilityConfigurationProperty(
        observability_configuration_arn="observabilityConfigurationArn",
        observability_enabled=False
    ),
    service_name="serviceName",
    source_configuration=apprunner_mixins.CfnServicePropsMixin.SourceConfigurationProperty(
        authentication_configuration=apprunner_mixins.CfnServicePropsMixin.AuthenticationConfigurationProperty(
            access_role_arn="accessRoleArn",
            connection_arn="connectionArn"
        ),
        auto_deployments_enabled=False,
        code_repository=apprunner_mixins.CfnServicePropsMixin.CodeRepositoryProperty(
            code_configuration=apprunner_mixins.CfnServicePropsMixin.CodeConfigurationProperty(
                code_configuration_values=apprunner_mixins.CfnServicePropsMixin.CodeConfigurationValuesProperty(
                    build_command="buildCommand",
                    port="port",
                    runtime="runtime",
                    runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                        name="name",
                        value="value"
                    )],
                    runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                        name="name",
                        value="value"
                    )],
                    start_command="startCommand"
                ),
                configuration_source="configurationSource"
            ),
            repository_url="repositoryUrl",
            source_code_version=apprunner_mixins.CfnServicePropsMixin.SourceCodeVersionProperty(
                type="type",
                value="value"
            ),
            source_directory="sourceDirectory"
        ),
        image_repository=apprunner_mixins.CfnServicePropsMixin.ImageRepositoryProperty(
            image_configuration=apprunner_mixins.CfnServicePropsMixin.ImageConfigurationProperty(
                port="port",
                runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                    name="name",
                    value="value"
                )],
                runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                    name="name",
                    value="value"
                )],
                start_command="startCommand"
            ),
            image_identifier="imageIdentifier",
            image_repository_type="imageRepositoryType"
        )
    ),
    tags=[CfnTag(
        key="key",
        value="value"
    )]
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::AppRunner::Service.

Parameters:
  • props (Union[CfnServiceMixinProps, Dict[str, Any]]) – L1 properties to apply.

  • strategy (Optional[PropertyMergeStrategy]) – (experimental) Strategy for merging nested properties. Default: - PropertyMergeStrategy.MERGE

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['autoScalingConfigurationArn', 'encryptionConfiguration', 'healthCheckConfiguration', 'instanceConfiguration', 'networkConfiguration', 'observabilityConfiguration', 'serviceName', 'sourceConfiguration', 'tags']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

AuthenticationConfigurationProperty

class CfnServicePropsMixin.AuthenticationConfigurationProperty(*, access_role_arn=None, connection_arn=None)

Bases: object

Describes resources needed to authenticate access to some source repositories.

The specific resource depends on the repository provider.

Parameters:
  • access_role_arn (Optional[str]) – The Amazon Resource Name (ARN) of the IAM role that grants the App Runner service access to a source repository. It’s required for ECR image repositories (but not for ECR Public repositories).

  • connection_arn (Optional[str]) – The Amazon Resource Name (ARN) of the App Runner connection that enables the App Runner service to connect to a source repository. It’s required for GitHub code repositories.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-authenticationconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

authentication_configuration_property = apprunner_mixins.CfnServicePropsMixin.AuthenticationConfigurationProperty(
    access_role_arn="accessRoleArn",
    connection_arn="connectionArn"
)

Attributes

access_role_arn

The Amazon Resource Name (ARN) of the IAM role that grants the App Runner service access to a source repository.

It’s required for ECR image repositories (but not for ECR Public repositories).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-authenticationconfiguration.html#cfn-apprunner-service-authenticationconfiguration-accessrolearn

connection_arn

The Amazon Resource Name (ARN) of the App Runner connection that enables the App Runner service to connect to a source repository.

It’s required for GitHub code repositories.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-authenticationconfiguration.html#cfn-apprunner-service-authenticationconfiguration-connectionarn

CodeConfigurationProperty

class CfnServicePropsMixin.CodeConfigurationProperty(*, code_configuration_values=None, configuration_source=None)

Bases: object

Describes the configuration that AWS App Runner uses to build and run an App Runner service from a source code repository.

Parameters:
  • code_configuration_values (Union[IResolvable, CodeConfigurationValuesProperty, Dict[str, Any], None]) – The basic configuration for building and running the App Runner service. Use it to quickly launch an App Runner service without providing a apprunner.yaml file in the source code repository (or ignoring the file if it exists).

  • configuration_source (Optional[str]) – The source of the App Runner configuration. Values are interpreted as follows:. - REPOSITORY – App Runner reads configuration values from the apprunner.yaml file in the source code repository and ignores CodeConfigurationValues . - API – App Runner uses configuration values provided in CodeConfigurationValues and ignores the apprunner.yaml file in the source code repository.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

code_configuration_property = apprunner_mixins.CfnServicePropsMixin.CodeConfigurationProperty(
    code_configuration_values=apprunner_mixins.CfnServicePropsMixin.CodeConfigurationValuesProperty(
        build_command="buildCommand",
        port="port",
        runtime="runtime",
        runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
            name="name",
            value="value"
        )],
        runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
            name="name",
            value="value"
        )],
        start_command="startCommand"
    ),
    configuration_source="configurationSource"
)

Attributes

code_configuration_values

The basic configuration for building and running the App Runner service.

Use it to quickly launch an App Runner service without providing a apprunner.yaml file in the source code repository (or ignoring the file if it exists).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfiguration.html#cfn-apprunner-service-codeconfiguration-codeconfigurationvalues

configuration_source

.

  • REPOSITORY – App Runner reads configuration values from the apprunner.yaml file in the source code repository and ignores CodeConfigurationValues .

  • API – App Runner uses configuration values provided in CodeConfigurationValues and ignores the apprunner.yaml file in the source code repository.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfiguration.html#cfn-apprunner-service-codeconfiguration-configurationsource

Type:

The source of the App Runner configuration. Values are interpreted as follows

CodeConfigurationValuesProperty

class CfnServicePropsMixin.CodeConfigurationValuesProperty(*, build_command=None, port=None, runtime=None, runtime_environment_secrets=None, runtime_environment_variables=None, start_command=None)

Bases: object

Describes the basic configuration needed for building and running an AWS App Runner service.

This type doesn’t support the full set of possible configuration options. Fur full configuration capabilities, use a apprunner.yaml file in the source code repository.

Parameters:
  • build_command (Optional[str]) – The command App Runner runs to build your application.

  • port (Optional[str]) – The port that your application listens to in the container. Default: 8080

  • runtime (Optional[str]) – A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

  • runtime_environment_secrets (Union[IResolvable, Sequence[Union[IResolvable, KeyValuePairProperty, Dict[str, Any]]], None]) – An array of key-value pairs representing the secrets and parameters that get referenced to your service as an environment variable. The supported values are either the full Amazon Resource Name (ARN) of the AWS Secrets Manager secret or the full ARN of the parameter in the AWS Systems Manager Parameter Store. .. epigraph:: - If the AWS Systems Manager Parameter Store parameter exists in the same AWS Region as the service that you’re launching, you can use either the full ARN or name of the secret. If the parameter exists in a different Region, then the full ARN must be specified. - Currently, cross account referencing of AWS Systems Manager Parameter Store parameter is not supported.

  • runtime_environment_variables (Union[IResolvable, Sequence[Union[IResolvable, KeyValuePairProperty, Dict[str, Any]]], None]) – The environment variables that are available to your running AWS App Runner service. An array of key-value pairs.

  • start_command (Optional[str]) – The command App Runner runs to start your application.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

code_configuration_values_property = apprunner_mixins.CfnServicePropsMixin.CodeConfigurationValuesProperty(
    build_command="buildCommand",
    port="port",
    runtime="runtime",
    runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
        name="name",
        value="value"
    )],
    runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
        name="name",
        value="value"
    )],
    start_command="startCommand"
)

Attributes

build_command

The command App Runner runs to build your application.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-buildcommand

port

The port that your application listens to in the container.

Default: 8080

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-port

runtime

A runtime environment type for building and running an App Runner service.

It represents a programming language runtime.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-runtime

runtime_environment_secrets

An array of key-value pairs representing the secrets and parameters that get referenced to your service as an environment variable.

The supported values are either the full Amazon Resource Name (ARN) of the AWS Secrets Manager secret or the full ARN of the parameter in the AWS Systems Manager Parameter Store. .. epigraph:

- If the AWS Systems Manager Parameter Store parameter exists in the same AWS Region as the service that you're launching, you can use either the full ARN or name of the secret. If the parameter exists in a different Region, then the full ARN must be specified.
- Currently, cross account referencing of AWS Systems Manager Parameter Store parameter is not supported.
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-runtimeenvironmentsecrets

runtime_environment_variables

The environment variables that are available to your running AWS App Runner service.

An array of key-value pairs.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-runtimeenvironmentvariables

start_command

The command App Runner runs to start your application.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-codeconfigurationvalues.html#cfn-apprunner-service-codeconfigurationvalues-startcommand

CodeRepositoryProperty

class CfnServicePropsMixin.CodeRepositoryProperty(*, code_configuration=None, repository_url=None, source_code_version=None, source_directory=None)

Bases: object

Describes a source code repository.

Parameters:
  • code_configuration (Union[IResolvable, CodeConfigurationProperty, Dict[str, Any], None]) – Configuration for building and running the service from a source code repository. .. epigraph:: CodeConfiguration is required only for CreateService request.

  • repository_url (Optional[str]) – The location of the repository that contains the source code.

  • source_code_version (Union[IResolvable, SourceCodeVersionProperty, Dict[str, Any], None]) – The version that should be used within the source code repository.

  • source_directory (Optional[str]) – The path of the directory that stores source code and configuration files. The build and start commands also execute from here. The path is absolute from root and, if not specified, defaults to the repository root.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-coderepository.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

code_repository_property = apprunner_mixins.CfnServicePropsMixin.CodeRepositoryProperty(
    code_configuration=apprunner_mixins.CfnServicePropsMixin.CodeConfigurationProperty(
        code_configuration_values=apprunner_mixins.CfnServicePropsMixin.CodeConfigurationValuesProperty(
            build_command="buildCommand",
            port="port",
            runtime="runtime",
            runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                name="name",
                value="value"
            )],
            runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                name="name",
                value="value"
            )],
            start_command="startCommand"
        ),
        configuration_source="configurationSource"
    ),
    repository_url="repositoryUrl",
    source_code_version=apprunner_mixins.CfnServicePropsMixin.SourceCodeVersionProperty(
        type="type",
        value="value"
    ),
    source_directory="sourceDirectory"
)

Attributes

code_configuration

Configuration for building and running the service from a source code repository.

CodeConfiguration is required only for CreateService request.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-coderepository.html#cfn-apprunner-service-coderepository-codeconfiguration

repository_url

The location of the repository that contains the source code.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-coderepository.html#cfn-apprunner-service-coderepository-repositoryurl

source_code_version

The version that should be used within the source code repository.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-coderepository.html#cfn-apprunner-service-coderepository-sourcecodeversion

source_directory

The path of the directory that stores source code and configuration files.

The build and start commands also execute from here. The path is absolute from root and, if not specified, defaults to the repository root.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-coderepository.html#cfn-apprunner-service-coderepository-sourcedirectory

EgressConfigurationProperty

class CfnServicePropsMixin.EgressConfigurationProperty(*, egress_type=None, vpc_connector_arn=None)

Bases: object

Describes configuration settings related to outbound network traffic of an AWS App Runner service.

Parameters:
  • egress_type (Optional[str]) – The type of egress configuration. Set to DEFAULT for access to resources hosted on public networks. Set to VPC to associate your service to a custom VPC specified by VpcConnectorArn .

  • vpc_connector_arn (Optional[str]) – The Amazon Resource Name (ARN) of the App Runner VPC connector that you want to associate with your App Runner service. Only valid when EgressType = VPC .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-egressconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

egress_configuration_property = apprunner_mixins.CfnServicePropsMixin.EgressConfigurationProperty(
    egress_type="egressType",
    vpc_connector_arn="vpcConnectorArn"
)

Attributes

egress_type

The type of egress configuration.

Set to DEFAULT for access to resources hosted on public networks.

Set to VPC to associate your service to a custom VPC specified by VpcConnectorArn .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-egressconfiguration.html#cfn-apprunner-service-egressconfiguration-egresstype

vpc_connector_arn

The Amazon Resource Name (ARN) of the App Runner VPC connector that you want to associate with your App Runner service.

Only valid when EgressType = VPC .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-egressconfiguration.html#cfn-apprunner-service-egressconfiguration-vpcconnectorarn

EncryptionConfigurationProperty

class CfnServicePropsMixin.EncryptionConfigurationProperty(*, kms_key=None)

Bases: object

Describes a custom encryption key that AWS App Runner uses to encrypt copies of the source repository and service logs.

Parameters:

kms_key (Optional[str]) – The ARN of the KMS key that’s used for encryption.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-encryptionconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

encryption_configuration_property = apprunner_mixins.CfnServicePropsMixin.EncryptionConfigurationProperty(
    kms_key="kmsKey"
)

Attributes

kms_key

The ARN of the KMS key that’s used for encryption.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-encryptionconfiguration.html#cfn-apprunner-service-encryptionconfiguration-kmskey

HealthCheckConfigurationProperty

class CfnServicePropsMixin.HealthCheckConfigurationProperty(*, healthy_threshold=None, interval=None, path=None, protocol=None, timeout=None, unhealthy_threshold=None)

Bases: object

Describes the settings for the health check that AWS App Runner performs to monitor the health of a service.

Parameters:
  • healthy_threshold (Union[int, float, None]) – The number of consecutive checks that must succeed before App Runner decides that the service is healthy. Default: 1

  • interval (Union[int, float, None]) – The time interval, in seconds, between health checks. Default: 5

  • path (Optional[str]) – The URL that health check requests are sent to. Path is only applicable when you set Protocol to HTTP . Default: "/"

  • protocol (Optional[str]) – The IP protocol that App Runner uses to perform health checks for your service. If you set Protocol to HTTP , App Runner sends health check requests to the HTTP path specified by Path . Default: TCP

  • timeout (Union[int, float, None]) – The time, in seconds, to wait for a health check response before deciding it failed. Default: 2

  • unhealthy_threshold (Union[int, float, None]) – The number of consecutive checks that must fail before App Runner decides that the service is unhealthy. Default: 5

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-healthcheckconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

health_check_configuration_property = apprunner_mixins.CfnServicePropsMixin.HealthCheckConfigurationProperty(
    healthy_threshold=123,
    interval=123,
    path="path",
    protocol="protocol",
    timeout=123,
    unhealthy_threshold=123
)

Attributes

healthy_threshold

The number of consecutive checks that must succeed before App Runner decides that the service is healthy.

Default: 1

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-healthcheckconfiguration.html#cfn-apprunner-service-healthcheckconfiguration-healthythreshold

interval

The time interval, in seconds, between health checks.

Default: 5

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-healthcheckconfiguration.html#cfn-apprunner-service-healthcheckconfiguration-interval

path

The URL that health check requests are sent to.

Path is only applicable when you set Protocol to HTTP .

Default: "/"

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-healthcheckconfiguration.html#cfn-apprunner-service-healthcheckconfiguration-path

protocol

The IP protocol that App Runner uses to perform health checks for your service.

If you set Protocol to HTTP , App Runner sends health check requests to the HTTP path specified by Path .

Default: TCP

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-healthcheckconfiguration.html#cfn-apprunner-service-healthcheckconfiguration-protocol

timeout

The time, in seconds, to wait for a health check response before deciding it failed.

Default: 2

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-healthcheckconfiguration.html#cfn-apprunner-service-healthcheckconfiguration-timeout

unhealthy_threshold

The number of consecutive checks that must fail before App Runner decides that the service is unhealthy.

Default: 5

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-healthcheckconfiguration.html#cfn-apprunner-service-healthcheckconfiguration-unhealthythreshold

ImageConfigurationProperty

class CfnServicePropsMixin.ImageConfigurationProperty(*, port=None, runtime_environment_secrets=None, runtime_environment_variables=None, start_command=None)

Bases: object

Describes the configuration that AWS App Runner uses to run an App Runner service using an image pulled from a source image repository.

Parameters:
  • port (Optional[str]) – The port that your application listens to in the container. Default: 8080

  • runtime_environment_secrets (Union[IResolvable, Sequence[Union[IResolvable, KeyValuePairProperty, Dict[str, Any]]], None]) – An array of key-value pairs representing the secrets and parameters that get referenced to your service as an environment variable. The supported values are either the full Amazon Resource Name (ARN) of the AWS Secrets Manager secret or the full ARN of the parameter in the AWS Systems Manager Parameter Store. .. epigraph:: - If the AWS Systems Manager Parameter Store parameter exists in the same AWS Region as the service that you’re launching, you can use either the full ARN or name of the secret. If the parameter exists in a different Region, then the full ARN must be specified. - Currently, cross account referencing of AWS Systems Manager Parameter Store parameter is not supported.

  • runtime_environment_variables (Union[IResolvable, Sequence[Union[IResolvable, KeyValuePairProperty, Dict[str, Any]]], None]) – Environment variables that are available to your running App Runner service. An array of key-value pairs.

  • start_command (Optional[str]) – An optional command that App Runner runs to start the application in the source image. If specified, this command overrides the Docker image’s default start command.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imageconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

image_configuration_property = apprunner_mixins.CfnServicePropsMixin.ImageConfigurationProperty(
    port="port",
    runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
        name="name",
        value="value"
    )],
    runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
        name="name",
        value="value"
    )],
    start_command="startCommand"
)

Attributes

port

The port that your application listens to in the container.

Default: 8080

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imageconfiguration.html#cfn-apprunner-service-imageconfiguration-port

runtime_environment_secrets

An array of key-value pairs representing the secrets and parameters that get referenced to your service as an environment variable.

The supported values are either the full Amazon Resource Name (ARN) of the AWS Secrets Manager secret or the full ARN of the parameter in the AWS Systems Manager Parameter Store. .. epigraph:

- If the AWS Systems Manager Parameter Store parameter exists in the same AWS Region as the service that you're launching, you can use either the full ARN or name of the secret. If the parameter exists in a different Region, then the full ARN must be specified.
- Currently, cross account referencing of AWS Systems Manager Parameter Store parameter is not supported.
See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imageconfiguration.html#cfn-apprunner-service-imageconfiguration-runtimeenvironmentsecrets

runtime_environment_variables

Environment variables that are available to your running App Runner service.

An array of key-value pairs.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imageconfiguration.html#cfn-apprunner-service-imageconfiguration-runtimeenvironmentvariables

start_command

An optional command that App Runner runs to start the application in the source image.

If specified, this command overrides the Docker image’s default start command.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imageconfiguration.html#cfn-apprunner-service-imageconfiguration-startcommand

ImageRepositoryProperty

class CfnServicePropsMixin.ImageRepositoryProperty(*, image_configuration=None, image_identifier=None, image_repository_type=None)

Bases: object

Describes a source image repository.

Parameters:
  • image_configuration (Union[IResolvable, ImageConfigurationProperty, Dict[str, Any], None]) – Configuration for running the identified image.

  • image_identifier (Optional[str]) – The identifier of an image. For an image in Amazon Elastic Container Registry (Amazon ECR), this is an image name. For the image name format, see Pulling an image in the Amazon ECR User Guide .

  • image_repository_type (Optional[str]) – The type of the image repository. This reflects the repository provider and whether the repository is private or public.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imagerepository.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

image_repository_property = apprunner_mixins.CfnServicePropsMixin.ImageRepositoryProperty(
    image_configuration=apprunner_mixins.CfnServicePropsMixin.ImageConfigurationProperty(
        port="port",
        runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
            name="name",
            value="value"
        )],
        runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
            name="name",
            value="value"
        )],
        start_command="startCommand"
    ),
    image_identifier="imageIdentifier",
    image_repository_type="imageRepositoryType"
)

Attributes

image_configuration

Configuration for running the identified image.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imagerepository.html#cfn-apprunner-service-imagerepository-imageconfiguration

image_identifier

The identifier of an image.

For an image in Amazon Elastic Container Registry (Amazon ECR), this is an image name. For the image name format, see Pulling an image in the Amazon ECR User Guide .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imagerepository.html#cfn-apprunner-service-imagerepository-imageidentifier

image_repository_type

The type of the image repository.

This reflects the repository provider and whether the repository is private or public.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-imagerepository.html#cfn-apprunner-service-imagerepository-imagerepositorytype

IngressConfigurationProperty

class CfnServicePropsMixin.IngressConfigurationProperty(*, is_publicly_accessible=None)

Bases: object

Network configuration settings for inbound network traffic.

Parameters:

is_publicly_accessible (Union[bool, IResolvable, None]) – Specifies whether your App Runner service is publicly accessible. To make the service publicly accessible set it to True . To make the service privately accessible, from only within an Amazon VPC set it to False .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-ingressconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

ingress_configuration_property = apprunner_mixins.CfnServicePropsMixin.IngressConfigurationProperty(
    is_publicly_accessible=False
)

Attributes

is_publicly_accessible

Specifies whether your App Runner service is publicly accessible.

To make the service publicly accessible set it to True . To make the service privately accessible, from only within an Amazon VPC set it to False .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-ingressconfiguration.html#cfn-apprunner-service-ingressconfiguration-ispubliclyaccessible

InstanceConfigurationProperty

class CfnServicePropsMixin.InstanceConfigurationProperty(*, cpu=None, instance_role_arn=None, memory=None)

Bases: object

Describes the runtime configuration of an AWS App Runner service instance (scaling unit).

Parameters:
  • cpu (Optional[str]) – The number of CPU units reserved for each instance of your App Runner service. Default: 1 vCPU

  • instance_role_arn (Optional[str]) – The Amazon Resource Name (ARN) of an IAM role that provides permissions to your App Runner service. These are permissions that your code needs when it calls any AWS APIs.

  • memory (Optional[str]) – The amount of memory, in MB or GB, reserved for each instance of your App Runner service. Default: 2 GB

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-instanceconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

instance_configuration_property = apprunner_mixins.CfnServicePropsMixin.InstanceConfigurationProperty(
    cpu="cpu",
    instance_role_arn="instanceRoleArn",
    memory="memory"
)

Attributes

cpu

The number of CPU units reserved for each instance of your App Runner service.

Default: 1 vCPU

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-instanceconfiguration.html#cfn-apprunner-service-instanceconfiguration-cpu

instance_role_arn

The Amazon Resource Name (ARN) of an IAM role that provides permissions to your App Runner service.

These are permissions that your code needs when it calls any AWS APIs.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-instanceconfiguration.html#cfn-apprunner-service-instanceconfiguration-instancerolearn

memory

The amount of memory, in MB or GB, reserved for each instance of your App Runner service.

Default: 2 GB

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-instanceconfiguration.html#cfn-apprunner-service-instanceconfiguration-memory

KeyValuePairProperty

class CfnServicePropsMixin.KeyValuePairProperty(*, name=None, value=None)

Bases: object

Describes a key-value pair, which is a string-to-string mapping.

Parameters:
  • name (Optional[str]) – The key name string to map to a value.

  • value (Optional[str]) – The value string to which the key name is mapped.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-keyvaluepair.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

key_value_pair_property = apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
    name="name",
    value="value"
)

Attributes

name

The key name string to map to a value.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-keyvaluepair.html#cfn-apprunner-service-keyvaluepair-name

value

The value string to which the key name is mapped.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-keyvaluepair.html#cfn-apprunner-service-keyvaluepair-value

NetworkConfigurationProperty

class CfnServicePropsMixin.NetworkConfigurationProperty(*, egress_configuration=None, ingress_configuration=None, ip_address_type=None)

Bases: object

Describes configuration settings related to network traffic of an AWS App Runner service.

Consists of embedded objects for each configurable network feature.

Parameters:
  • egress_configuration (Union[IResolvable, EgressConfigurationProperty, Dict[str, Any], None]) – Network configuration settings for outbound message traffic.

  • ingress_configuration (Union[IResolvable, IngressConfigurationProperty, Dict[str, Any], None]) – Network configuration settings for inbound message traffic.

  • ip_address_type (Optional[str]) – App Runner provides you with the option to choose between IPv4 and dual stack (IPv4 and IPv6) for your incoming public network configuration. This is an optional parameter. If you do not specify an IpAddressType , it defaults to select IPv4.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-networkconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

network_configuration_property = apprunner_mixins.CfnServicePropsMixin.NetworkConfigurationProperty(
    egress_configuration=apprunner_mixins.CfnServicePropsMixin.EgressConfigurationProperty(
        egress_type="egressType",
        vpc_connector_arn="vpcConnectorArn"
    ),
    ingress_configuration=apprunner_mixins.CfnServicePropsMixin.IngressConfigurationProperty(
        is_publicly_accessible=False
    ),
    ip_address_type="ipAddressType"
)

Attributes

egress_configuration

Network configuration settings for outbound message traffic.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-networkconfiguration.html#cfn-apprunner-service-networkconfiguration-egressconfiguration

ingress_configuration

Network configuration settings for inbound message traffic.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-networkconfiguration.html#cfn-apprunner-service-networkconfiguration-ingressconfiguration

ip_address_type

App Runner provides you with the option to choose between IPv4 and dual stack (IPv4 and IPv6) for your incoming public network configuration.

This is an optional parameter. If you do not specify an IpAddressType , it defaults to select IPv4.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-networkconfiguration.html#cfn-apprunner-service-networkconfiguration-ipaddresstype

ServiceObservabilityConfigurationProperty

class CfnServicePropsMixin.ServiceObservabilityConfigurationProperty(*, observability_configuration_arn=None, observability_enabled=None)

Bases: object

Describes the observability configuration of an AWS App Runner service.

These are additional observability features, like tracing, that you choose to enable. They’re configured in a separate resource that you associate with your service.

Parameters:
  • observability_configuration_arn (Optional[str]) – The Amazon Resource Name (ARN) of the observability configuration that is associated with the service. Specified only when ObservabilityEnabled is true . Specify an ARN with a name and a revision number to associate that revision. For example: arn:aws:apprunner:us-east-1:123456789012:observabilityconfiguration/xray-tracing/3 Specify just the name to associate the latest revision. For example: arn:aws:apprunner:us-east-1:123456789012:observabilityconfiguration/xray-tracing

  • observability_enabled (Union[bool, IResolvable, None]) – When true , an observability configuration resource is associated with the service, and an ObservabilityConfigurationArn is specified.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-serviceobservabilityconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

service_observability_configuration_property = apprunner_mixins.CfnServicePropsMixin.ServiceObservabilityConfigurationProperty(
    observability_configuration_arn="observabilityConfigurationArn",
    observability_enabled=False
)

Attributes

observability_configuration_arn

The Amazon Resource Name (ARN) of the observability configuration that is associated with the service.

Specified only when ObservabilityEnabled is true .

Specify an ARN with a name and a revision number to associate that revision. For example: arn:aws:apprunner:us-east-1:123456789012:observabilityconfiguration/xray-tracing/3

Specify just the name to associate the latest revision. For example: arn:aws:apprunner:us-east-1:123456789012:observabilityconfiguration/xray-tracing

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-serviceobservabilityconfiguration.html#cfn-apprunner-service-serviceobservabilityconfiguration-observabilityconfigurationarn

observability_enabled

When true , an observability configuration resource is associated with the service, and an ObservabilityConfigurationArn is specified.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-serviceobservabilityconfiguration.html#cfn-apprunner-service-serviceobservabilityconfiguration-observabilityenabled

SourceCodeVersionProperty

class CfnServicePropsMixin.SourceCodeVersionProperty(*, type=None, value=None)

Bases: object

Identifies a version of code that AWS App Runner refers to within a source code repository.

Parameters:
  • type (Optional[str]) – The type of version identifier. For a git-based repository, branches represent versions.

  • value (Optional[str]) – A source code version. For a git-based repository, a branch name maps to a specific version. App Runner uses the most recent commit to the branch.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourcecodeversion.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

source_code_version_property = apprunner_mixins.CfnServicePropsMixin.SourceCodeVersionProperty(
    type="type",
    value="value"
)

Attributes

type

The type of version identifier.

For a git-based repository, branches represent versions.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourcecodeversion.html#cfn-apprunner-service-sourcecodeversion-type

value

A source code version.

For a git-based repository, a branch name maps to a specific version. App Runner uses the most recent commit to the branch.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourcecodeversion.html#cfn-apprunner-service-sourcecodeversion-value

SourceConfigurationProperty

class CfnServicePropsMixin.SourceConfigurationProperty(*, authentication_configuration=None, auto_deployments_enabled=None, code_repository=None, image_repository=None)

Bases: object

Describes the source deployed to an AWS App Runner service.

It can be a code or an image repository.

Parameters:
  • authentication_configuration (Union[IResolvable, AuthenticationConfigurationProperty, Dict[str, Any], None]) – Describes the resources that are needed to authenticate access to some source repositories.

  • auto_deployments_enabled (Union[bool, IResolvable, None]) – If true , continuous integration from the source repository is enabled for the App Runner service. Each repository change (including any source code commit or new image version) starts a deployment. Default: App Runner sets to false for a source image that uses an ECR Public repository or an ECR repository that’s in an AWS account other than the one that the service is in. App Runner sets to true in all other cases (which currently include a source code repository or a source image using a same-account ECR repository).

  • code_repository (Union[IResolvable, CodeRepositoryProperty, Dict[str, Any], None]) – The description of a source code repository. You must provide either this member or ImageRepository (but not both).

  • image_repository (Union[IResolvable, ImageRepositoryProperty, Dict[str, Any], None]) – The description of a source image repository. You must provide either this member or CodeRepository (but not both).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourceconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_apprunner import mixins as apprunner_mixins

source_configuration_property = apprunner_mixins.CfnServicePropsMixin.SourceConfigurationProperty(
    authentication_configuration=apprunner_mixins.CfnServicePropsMixin.AuthenticationConfigurationProperty(
        access_role_arn="accessRoleArn",
        connection_arn="connectionArn"
    ),
    auto_deployments_enabled=False,
    code_repository=apprunner_mixins.CfnServicePropsMixin.CodeRepositoryProperty(
        code_configuration=apprunner_mixins.CfnServicePropsMixin.CodeConfigurationProperty(
            code_configuration_values=apprunner_mixins.CfnServicePropsMixin.CodeConfigurationValuesProperty(
                build_command="buildCommand",
                port="port",
                runtime="runtime",
                runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                    name="name",
                    value="value"
                )],
                runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                    name="name",
                    value="value"
                )],
                start_command="startCommand"
            ),
            configuration_source="configurationSource"
        ),
        repository_url="repositoryUrl",
        source_code_version=apprunner_mixins.CfnServicePropsMixin.SourceCodeVersionProperty(
            type="type",
            value="value"
        ),
        source_directory="sourceDirectory"
    ),
    image_repository=apprunner_mixins.CfnServicePropsMixin.ImageRepositoryProperty(
        image_configuration=apprunner_mixins.CfnServicePropsMixin.ImageConfigurationProperty(
            port="port",
            runtime_environment_secrets=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                name="name",
                value="value"
            )],
            runtime_environment_variables=[apprunner_mixins.CfnServicePropsMixin.KeyValuePairProperty(
                name="name",
                value="value"
            )],
            start_command="startCommand"
        ),
        image_identifier="imageIdentifier",
        image_repository_type="imageRepositoryType"
    )
)

Attributes

authentication_configuration

Describes the resources that are needed to authenticate access to some source repositories.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourceconfiguration.html#cfn-apprunner-service-sourceconfiguration-authenticationconfiguration

auto_deployments_enabled

If true , continuous integration from the source repository is enabled for the App Runner service.

Each repository change (including any source code commit or new image version) starts a deployment.

Default: App Runner sets to false for a source image that uses an ECR Public repository or an ECR repository that’s in an AWS account other than the one that the service is in. App Runner sets to true in all other cases (which currently include a source code repository or a source image using a same-account ECR repository).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourceconfiguration.html#cfn-apprunner-service-sourceconfiguration-autodeploymentsenabled

code_repository

The description of a source code repository.

You must provide either this member or ImageRepository (but not both).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourceconfiguration.html#cfn-apprunner-service-sourceconfiguration-coderepository

image_repository

The description of a source image repository.

You must provide either this member or CodeRepository (but not both).

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-apprunner-service-sourceconfiguration.html#cfn-apprunner-service-sourceconfiguration-imagerepository