AppRunner

Client

class AppRunner.Client

A low-level client representing AWS App Runner

App Runner is an application service that provides a fast, simple, and cost-effective way to go directly from an existing container image or source code to a running service in the Amazon Web Services Cloud in seconds. You don't need to learn new technologies, decide which compute service to use, or understand how to provision and configure Amazon Web Services resources.

App Runner connects directly to your container registry or source code repository. It provides an automatic delivery pipeline with fully managed operations, high performance, scalability, and security.

For more information about App Runner, see the App Runner Developer Guide . For release information, see the App Runner Release Notes .

To install the Software Development Kits (SDKs), Integrated Development Environment (IDE) Toolkits, and command line tools that you can use to access the API, see Tools for Amazon Web Services .

Endpoints

For a list of Region-specific endpoints that App Runner supports, see App Runner endpoints and quotas in the Amazon Web Services General Reference .

client = session.create_client('apprunner')

These are the available methods:

associate_custom_domain(**kwargs)

Associate your own domain name with the App Runner subdomain URL of your App Runner service.

After you call AssociateCustomDomain and receive a successful response, use the information in the CustomDomain record that's returned to add CNAME records to your Domain Name System (DNS). For each mapped domain name, add a mapping to the target App Runner subdomain and one or more certificate validation records. App Runner then performs DNS validation to verify that you own or control the domain name that you associated. App Runner tracks domain validity in a certificate stored in AWS Certificate Manager (ACM) .

See also: AWS API Documentation

Request Syntax

response = client.associate_custom_domain(
    ServiceArn='string',
    DomainName='string',
    EnableWWWSubdomain=True|False
)
Parameters
  • ServiceArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the App Runner service that you want to associate a custom domain name with.

  • DomainName (string) --

    [REQUIRED]

    A custom domain endpoint to associate. Specify a root domain (for example, example.com ), a subdomain (for example, login.example.com or admin.login.example.com ), or a wildcard (for example, *.example.com ).

  • EnableWWWSubdomain (boolean) --

    Set to true to associate the subdomain ``www.*DomainName* `` with the App Runner service in addition to the base domain.

    Default: true

Return type

dict

Returns

Response Syntax

{
    'DNSTarget': 'string',
    'ServiceArn': 'string',
    'CustomDomain': {
        'DomainName': 'string',
        'EnableWWWSubdomain': True|False,
        'CertificateValidationRecords': [
            {
                'Name': 'string',
                'Type': 'string',
                'Value': 'string',
                'Status': 'PENDING_VALIDATION'|'SUCCESS'|'FAILED'
            },
        ],
        'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'DELETING'|'DELETE_FAILED'|'PENDING_CERTIFICATE_DNS_VALIDATION'|'BINDING_CERTIFICATE'
    }
}

Response Structure

  • (dict) --

    • DNSTarget (string) --

      The App Runner subdomain of the App Runner service. The custom domain name is mapped to this target name.

    • ServiceArn (string) --

      The Amazon Resource Name (ARN) of the App Runner service with which a custom domain name is associated.

    • CustomDomain (dict) --

      A description of the domain name that's being associated.

      • DomainName (string) --

        An associated custom domain endpoint. It can be a root domain (for example, example.com ), a subdomain (for example, login.example.com or admin.login.example.com ), or a wildcard (for example, *.example.com ).

      • EnableWWWSubdomain (boolean) --

        When true , the subdomain ``www.*DomainName* `` is associated with the App Runner service in addition to the base domain.

      • CertificateValidationRecords (list) --

        A list of certificate CNAME records that's used for this domain name.

        • (dict) --

          Describes a certificate CNAME record to add to your DNS. For more information, see AssociateCustomDomain .

          • Name (string) --

            The certificate CNAME record name.

          • Type (string) --

            The record type, always CNAME .

          • Value (string) --

            The certificate CNAME record value.

          • Status (string) --

            The current state of the certificate CNAME record validation. It should change to SUCCESS after App Runner completes validation with your DNS.

      • Status (string) --

        The current state of the domain name association.

Exceptions

can_paginate(operation_name)

Check if an operation can be paginated.

Parameters
operation_name (string) -- The operation name. This is the same name as the method name on the client. For example, if the method name is create_foo, and you'd normally invoke the operation as client.create_foo(**kwargs), if the create_foo operation can be paginated, you can use the call client.get_paginator("create_foo").
Returns
True if the operation can be paginated, False otherwise.
create_auto_scaling_configuration(**kwargs)

Create an App Runner automatic scaling configuration resource. App Runner requires this resource when you create App Runner services that require non-default auto scaling settings. You can share an auto scaling configuration across multiple services.

Create multiple revisions of a configuration by using the same AutoScalingConfigurationName and different AutoScalingConfigurationRevision values. When you create a service, you can set it to use the latest active revision of an auto scaling configuration or a specific revision.

Configure a higher MinSize to increase the spread of your App Runner service over more Availability Zones in the Amazon Web Services Region. The tradeoff is a higher minimal cost.

Configure a lower MaxSize to control your cost. The tradeoff is lower responsiveness during peak demand.

See also: AWS API Documentation

Request Syntax

response = client.create_auto_scaling_configuration(
    AutoScalingConfigurationName='string',
    MaxConcurrency=123,
    MinSize=123,
    MaxSize=123,
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
)
Parameters
  • AutoScalingConfigurationName (string) --

    [REQUIRED]

    A name for the auto scaling configuration. When you use it for the first time in an Amazon Web Services Region, App Runner creates revision number 1 of this name. When you use the same name in subsequent calls, App Runner creates incremental revisions of the configuration.

  • MaxConcurrency (integer) --

    The maximum number of concurrent requests that you want an instance to process. If the number of concurrent requests exceeds this limit, App Runner scales up your service.

    Default: 100

  • MinSize (integer) --

    The minimum number of instances that App Runner provisions for your service. The service always has at least MinSize provisioned instances. Some of them actively serve traffic. The rest of them (provisioned and inactive instances) are a cost-effective compute capacity reserve and are ready to be quickly activated. You pay for memory usage of all the provisioned instances. You pay for CPU usage of only the active subset.

    App Runner temporarily doubles the number of provisioned instances during deployments, to maintain the same capacity for both old and new code.

    Default: 1

  • MaxSize (integer) --

    The maximum number of instances that your service scales up to. At most MaxSize instances actively serve traffic for your service.

    Default: 25

  • Tags (list) --

    A list of metadata items that you can associate with your auto scaling configuration resource. A tag is a key-value pair.

    • (dict) --

      Describes a tag that is applied to an App Runner resource. A tag is a metadata item consisting of a key-value pair.

      • Key (string) --

        The key of the tag.

      • Value (string) --

        The value of the tag.

Return type

dict

Returns

Response Syntax

{
    'AutoScalingConfiguration': {
        'AutoScalingConfigurationArn': 'string',
        'AutoScalingConfigurationName': 'string',
        'AutoScalingConfigurationRevision': 123,
        'Latest': True|False,
        'Status': 'ACTIVE'|'INACTIVE',
        'MaxConcurrency': 123,
        'MinSize': 123,
        'MaxSize': 123,
        'CreatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --

    • AutoScalingConfiguration (dict) --

      A description of the App Runner auto scaling configuration that's created by this request.

      • AutoScalingConfigurationArn (string) --

        The Amazon Resource Name (ARN) of this auto scaling configuration.

      • AutoScalingConfigurationName (string) --

        The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

      • AutoScalingConfigurationRevision (integer) --

        The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) that share the same AutoScalingConfigurationName .

      • Latest (boolean) --

        It's set to true for the configuration with the highest Revision among all configurations that share the same Name . It's set to false otherwise.

      • Status (string) --

        The current state of the auto scaling configuration. If the status of a configuration revision is INACTIVE , it was deleted and can't be used. Inactive configuration revisions are permanently removed some time after they are deleted.

      • MaxConcurrency (integer) --

        The maximum number of concurrent requests that an instance processes. If the number of concurrent requests exceeds this limit, App Runner scales the service up.

      • MinSize (integer) --

        The minimum number of instances that App Runner provisions for a service. The service always has at least MinSize provisioned instances. Some of them actively serve traffic. The rest of them (provisioned and inactive instances) are a cost-effective compute capacity reserve and are ready to be quickly activated. You pay for memory usage of all the provisioned instances. You pay for CPU usage of only the active subset.

        App Runner temporarily doubles the number of provisioned instances during deployments, to maintain the same capacity for both old and new code.

      • MaxSize (integer) --

        The maximum number of instances that a service scales up to. At most MaxSize instances actively serve traffic for your service.

      • CreatedAt (datetime) --

        The time when the auto scaling configuration was created. It's in Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the auto scaling configuration was deleted. It's in Unix time stamp format.

Exceptions

create_connection(**kwargs)

Create an App Runner connection resource. App Runner requires a connection resource when you create App Runner services that access private repositories from certain third-party providers. You can share a connection across multiple services.

A connection resource is needed to access GitHub repositories. GitHub requires a user interface approval process through the App Runner console before you can use the connection.

See also: AWS API Documentation

Request Syntax

response = client.create_connection(
    ConnectionName='string',
    ProviderType='GITHUB',
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
)
Parameters
  • ConnectionName (string) --

    [REQUIRED]

    A name for the new connection. It must be unique across all App Runner connections for the Amazon Web Services account in the Amazon Web Services Region.

  • ProviderType (string) --

    [REQUIRED]

    The source repository provider.

  • Tags (list) --

    A list of metadata items that you can associate with your connection resource. A tag is a key-value pair.

    • (dict) --

      Describes a tag that is applied to an App Runner resource. A tag is a metadata item consisting of a key-value pair.

      • Key (string) --

        The key of the tag.

      • Value (string) --

        The value of the tag.

Return type

dict

Returns

Response Syntax

{
    'Connection': {
        'ConnectionName': 'string',
        'ConnectionArn': 'string',
        'ProviderType': 'GITHUB',
        'Status': 'PENDING_HANDSHAKE'|'AVAILABLE'|'ERROR'|'DELETED',
        'CreatedAt': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --

    • Connection (dict) --

      A description of the App Runner connection that's created by this request.

      • ConnectionName (string) --

        The customer-provided connection name.

      • ConnectionArn (string) --

        The Amazon Resource Name (ARN) of this connection.

      • ProviderType (string) --

        The source repository provider.

      • Status (string) --

        The current state of the App Runner connection. When the state is AVAILABLE , you can use the connection to create an App Runner service.

      • CreatedAt (datetime) --

        The App Runner connection creation time, expressed as a Unix time stamp.

Exceptions

create_service(**kwargs)

Create an App Runner service. After the service is created, the action also automatically starts a deployment.

This is an asynchronous operation. On a successful call, you can use the returned OperationId and the ListOperations call to track the operation's progress.

See also: AWS API Documentation

Request Syntax

response = client.create_service(
    ServiceName='string',
    SourceConfiguration={
        'CodeRepository': {
            'RepositoryUrl': 'string',
            'SourceCodeVersion': {
                'Type': 'BRANCH',
                'Value': 'string'
            },
            'CodeConfiguration': {
                'ConfigurationSource': 'REPOSITORY'|'API',
                'CodeConfigurationValues': {
                    'Runtime': 'PYTHON_3'|'NODEJS_12',
                    'BuildCommand': 'string',
                    'StartCommand': 'string',
                    'Port': 'string',
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    }
                }
            }
        },
        'ImageRepository': {
            'ImageIdentifier': 'string',
            'ImageConfiguration': {
                'RuntimeEnvironmentVariables': {
                    'string': 'string'
                },
                'StartCommand': 'string',
                'Port': 'string'
            },
            'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
        },
        'AutoDeploymentsEnabled': True|False,
        'AuthenticationConfiguration': {
            'ConnectionArn': 'string',
            'AccessRoleArn': 'string'
        }
    },
    InstanceConfiguration={
        'Cpu': 'string',
        'Memory': 'string',
        'InstanceRoleArn': 'string'
    },
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ],
    EncryptionConfiguration={
        'KmsKey': 'string'
    },
    HealthCheckConfiguration={
        'Protocol': 'TCP'|'HTTP',
        'Path': 'string',
        'Interval': 123,
        'Timeout': 123,
        'HealthyThreshold': 123,
        'UnhealthyThreshold': 123
    },
    AutoScalingConfigurationArn='string'
)
Parameters
  • ServiceName (string) --

    [REQUIRED]

    A name for the new service. It must be unique across all the running App Runner services in your Amazon Web Services account in the Amazon Web Services Region.

  • SourceConfiguration (dict) --

    [REQUIRED]

    The source to deploy to the App Runner service. It can be a code or an image repository.

    • CodeRepository (dict) --

      The description of a source code repository.

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

      • RepositoryUrl (string) -- [REQUIRED]

        The location of the repository that contains the source code.

      • SourceCodeVersion (dict) -- [REQUIRED]

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

        • Type (string) -- [REQUIRED]

          The type of version identifier.

          For a git-based repository, branches represent versions.

        • Value (string) -- [REQUIRED]

          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.

      • CodeConfiguration (dict) --

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

        • ConfigurationSource (string) -- [REQUIRED]

          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.
        • CodeConfigurationValues (dict) --

          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).

          • Runtime (string) -- [REQUIRED]

            A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

          • BuildCommand (string) --

            The command App Runner runs to build your application.

          • StartCommand (string) --

            The command App Runner runs to start your application.

          • Port (string) --

            The port that your application listens to in the container.

            Default: 8080

          • RuntimeEnvironmentVariables (dict) --

            The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

            • (string) --
              • (string) --
    • ImageRepository (dict) --

      The description of a source image repository.

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

      • ImageIdentifier (string) -- [REQUIRED]

        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 .

      • ImageConfiguration (dict) --

        Configuration for running the identified image.

        • RuntimeEnvironmentVariables (dict) --

          Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

          • (string) --
            • (string) --
        • StartCommand (string) --

          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.

        • Port (string) --

          The port that your application listens to in the container.

          Default: 8080

      • ImageRepositoryType (string) -- [REQUIRED]

        The type of the image repository. This reflects the repository provider and whether the repository is private or public.

    • AutoDeploymentsEnabled (boolean) --

      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 Amazon Web Services 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).

    • AuthenticationConfiguration (dict) --

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

      • ConnectionArn (string) --

        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.

      • AccessRoleArn (string) --

        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).

  • InstanceConfiguration (dict) --

    The runtime configuration of instances (scaling units) of the App Runner service.

    • Cpu (string) --

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

      Default: 1 vCPU

    • Memory (string) --

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

      Default: 2 GB

    • InstanceRoleArn (string) --

      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 Amazon Web Services APIs.

  • Tags (list) --

    An optional list of metadata items that you can associate with your service resource. A tag is a key-value pair.

    • (dict) --

      Describes a tag that is applied to an App Runner resource. A tag is a metadata item consisting of a key-value pair.

      • Key (string) --

        The key of the tag.

      • Value (string) --

        The value of the tag.

  • EncryptionConfiguration (dict) --

    An optional custom encryption key that App Runner uses to encrypt the copy of your source repository that it maintains and your service logs. By default, App Runner uses an Amazon Web Services managed CMK.

    • KmsKey (string) -- [REQUIRED]

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

  • HealthCheckConfiguration (dict) --

    The settings for the health check that App Runner performs to monitor the health of your service.

    • Protocol (string) --

      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

    • Path (string) --

      The URL that health check requests are sent to.

      Path is only applicable when you set Protocol to HTTP .

      Default: "/"

    • Interval (integer) --

      The time interval, in seconds, between health checks.

      Default: 5

    • Timeout (integer) --

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

      Default: 2

    • HealthyThreshold (integer) --

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

      Default: 1

    • UnhealthyThreshold (integer) --

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

      Default: 5

  • AutoScalingConfigurationArn (string) -- The Amazon Resource Name (ARN) of an App Runner automatic scaling configuration resource that you want to associate with your service. If not provided, App Runner associates the latest revision of a default auto scaling configuration.
Return type

dict

Returns

Response Syntax

{
    'Service': {
        'ServiceName': 'string',
        'ServiceId': 'string',
        'ServiceArn': 'string',
        'ServiceUrl': 'string',
        'CreatedAt': datetime(2015, 1, 1),
        'UpdatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1),
        'Status': 'CREATE_FAILED'|'RUNNING'|'DELETED'|'DELETE_FAILED'|'PAUSED'|'OPERATION_IN_PROGRESS',
        'SourceConfiguration': {
            'CodeRepository': {
                'RepositoryUrl': 'string',
                'SourceCodeVersion': {
                    'Type': 'BRANCH',
                    'Value': 'string'
                },
                'CodeConfiguration': {
                    'ConfigurationSource': 'REPOSITORY'|'API',
                    'CodeConfigurationValues': {
                        'Runtime': 'PYTHON_3'|'NODEJS_12',
                        'BuildCommand': 'string',
                        'StartCommand': 'string',
                        'Port': 'string',
                        'RuntimeEnvironmentVariables': {
                            'string': 'string'
                        }
                    }
                }
            },
            'ImageRepository': {
                'ImageIdentifier': 'string',
                'ImageConfiguration': {
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    },
                    'StartCommand': 'string',
                    'Port': 'string'
                },
                'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
            },
            'AutoDeploymentsEnabled': True|False,
            'AuthenticationConfiguration': {
                'ConnectionArn': 'string',
                'AccessRoleArn': 'string'
            }
        },
        'InstanceConfiguration': {
            'Cpu': 'string',
            'Memory': 'string',
            'InstanceRoleArn': 'string'
        },
        'EncryptionConfiguration': {
            'KmsKey': 'string'
        },
        'HealthCheckConfiguration': {
            'Protocol': 'TCP'|'HTTP',
            'Path': 'string',
            'Interval': 123,
            'Timeout': 123,
            'HealthyThreshold': 123,
            'UnhealthyThreshold': 123
        },
        'AutoScalingConfigurationSummary': {
            'AutoScalingConfigurationArn': 'string',
            'AutoScalingConfigurationName': 'string',
            'AutoScalingConfigurationRevision': 123
        }
    },
    'OperationId': 'string'
}

Response Structure

  • (dict) --

    • Service (dict) --

      A description of the App Runner service that's created by this request.

      • ServiceName (string) --

        The customer-provided service name.

      • ServiceId (string) --

        An ID that App Runner generated for this service. It's unique within the Amazon Web Services Region.

      • ServiceArn (string) --

        The Amazon Resource Name (ARN) of this service.

      • ServiceUrl (string) --

        A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.

      • CreatedAt (datetime) --

        The time when the App Runner service was created. It's in the Unix time stamp format.

      • UpdatedAt (datetime) --

        The time when the App Runner service was last updated at. It's in the Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the App Runner service was deleted. It's in the Unix time stamp format.

      • Status (string) --

        The current state of the App Runner service. These particular values mean the following.

        • CREATE_FAILED – The service failed to create. To troubleshoot this failure, read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn't usable, and still counts towards your service quota. When you're done analyzing the failure, delete the service.
        • DELETE_FAILED – The service failed to delete and can't be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
      • SourceConfiguration (dict) --

        The source deployed to the App Runner service. It can be a code or an image repository.

        • CodeRepository (dict) --

          The description of a source code repository.

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

          • RepositoryUrl (string) --

            The location of the repository that contains the source code.

          • SourceCodeVersion (dict) --

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

            • Type (string) --

              The type of version identifier.

              For a git-based repository, branches represent versions.

            • Value (string) --

              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.

          • CodeConfiguration (dict) --

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

            • ConfigurationSource (string) --

              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.
            • CodeConfigurationValues (dict) --

              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).

              • Runtime (string) --

                A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

              • BuildCommand (string) --

                The command App Runner runs to build your application.

              • StartCommand (string) --

                The command App Runner runs to start your application.

              • Port (string) --

                The port that your application listens to in the container.

                Default: 8080

              • RuntimeEnvironmentVariables (dict) --

                The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

                • (string) --
                  • (string) --
        • ImageRepository (dict) --

          The description of a source image repository.

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

          • ImageIdentifier (string) --

            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 .

          • ImageConfiguration (dict) --

            Configuration for running the identified image.

            • RuntimeEnvironmentVariables (dict) --

              Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

              • (string) --
                • (string) --
            • StartCommand (string) --

              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.

            • Port (string) --

              The port that your application listens to in the container.

              Default: 8080

          • ImageRepositoryType (string) --

            The type of the image repository. This reflects the repository provider and whether the repository is private or public.

        • AutoDeploymentsEnabled (boolean) --

          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 Amazon Web Services 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).

        • AuthenticationConfiguration (dict) --

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

          • ConnectionArn (string) --

            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.

          • AccessRoleArn (string) --

            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).

      • InstanceConfiguration (dict) --

        The runtime configuration of instances (scaling units) of this service.

        • Cpu (string) --

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

          Default: 1 vCPU

        • Memory (string) --

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

          Default: 2 GB

        • InstanceRoleArn (string) --

          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 Amazon Web Services APIs.

      • EncryptionConfiguration (dict) --

        The encryption key that App Runner uses to encrypt the service logs and the copy of the source repository that App Runner maintains for the service. It can be either a customer-provided encryption key or an Amazon Web Services managed CMK.

        • KmsKey (string) --

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

      • HealthCheckConfiguration (dict) --

        The settings for the health check that App Runner performs to monitor the health of this service.

        • Protocol (string) --

          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

        • Path (string) --

          The URL that health check requests are sent to.

          Path is only applicable when you set Protocol to HTTP .

          Default: "/"

        • Interval (integer) --

          The time interval, in seconds, between health checks.

          Default: 5

        • Timeout (integer) --

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

          Default: 2

        • HealthyThreshold (integer) --

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

          Default: 1

        • UnhealthyThreshold (integer) --

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

          Default: 5

      • AutoScalingConfigurationSummary (dict) --

        Summary information for the App Runner automatic scaling configuration resource that's associated with this service.

        • AutoScalingConfigurationArn (string) --

          The Amazon Resource Name (ARN) of this auto scaling configuration.

        • AutoScalingConfigurationName (string) --

          The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

        • AutoScalingConfigurationRevision (integer) --

          The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) with the same AutoScalingConfigurationName .

    • OperationId (string) --

      The unique ID of the asynchronous operation that this request started. You can use it combined with the ListOperations call to track the operation's progress.

Exceptions

delete_auto_scaling_configuration(**kwargs)

Delete an App Runner automatic scaling configuration resource. You can delete a specific revision or the latest active revision. You can't delete a configuration that's used by one or more App Runner services.

See also: AWS API Documentation

Request Syntax

response = client.delete_auto_scaling_configuration(
    AutoScalingConfigurationArn='string'
)
Parameters
AutoScalingConfigurationArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner auto scaling configuration that you want to delete.

The ARN can be a full auto scaling configuration ARN, or a partial ARN ending with either ``.../name `` or ``.../name /revision `` . If a revision isn't specified, the latest active revision is deleted.

Return type
dict
Returns
Response Syntax
{
    'AutoScalingConfiguration': {
        'AutoScalingConfigurationArn': 'string',
        'AutoScalingConfigurationName': 'string',
        'AutoScalingConfigurationRevision': 123,
        'Latest': True|False,
        'Status': 'ACTIVE'|'INACTIVE',
        'MaxConcurrency': 123,
        'MinSize': 123,
        'MaxSize': 123,
        'CreatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --
    • AutoScalingConfiguration (dict) --

      A description of the App Runner auto scaling configuration that this request just deleted.

      • AutoScalingConfigurationArn (string) --

        The Amazon Resource Name (ARN) of this auto scaling configuration.

      • AutoScalingConfigurationName (string) --

        The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

      • AutoScalingConfigurationRevision (integer) --

        The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) that share the same AutoScalingConfigurationName .

      • Latest (boolean) --

        It's set to true for the configuration with the highest Revision among all configurations that share the same Name . It's set to false otherwise.

      • Status (string) --

        The current state of the auto scaling configuration. If the status of a configuration revision is INACTIVE , it was deleted and can't be used. Inactive configuration revisions are permanently removed some time after they are deleted.

      • MaxConcurrency (integer) --

        The maximum number of concurrent requests that an instance processes. If the number of concurrent requests exceeds this limit, App Runner scales the service up.

      • MinSize (integer) --

        The minimum number of instances that App Runner provisions for a service. The service always has at least MinSize provisioned instances. Some of them actively serve traffic. The rest of them (provisioned and inactive instances) are a cost-effective compute capacity reserve and are ready to be quickly activated. You pay for memory usage of all the provisioned instances. You pay for CPU usage of only the active subset.

        App Runner temporarily doubles the number of provisioned instances during deployments, to maintain the same capacity for both old and new code.

      • MaxSize (integer) --

        The maximum number of instances that a service scales up to. At most MaxSize instances actively serve traffic for your service.

      • CreatedAt (datetime) --

        The time when the auto scaling configuration was created. It's in Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the auto scaling configuration was deleted. It's in Unix time stamp format.

Exceptions

delete_connection(**kwargs)

Delete an App Runner connection. You must first ensure that there are no running App Runner services that use this connection. If there are any, the DeleteConnection action fails.

See also: AWS API Documentation

Request Syntax

response = client.delete_connection(
    ConnectionArn='string'
)
Parameters
ConnectionArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner connection that you want to delete.

Return type
dict
Returns
Response Syntax
{
    'Connection': {
        'ConnectionName': 'string',
        'ConnectionArn': 'string',
        'ProviderType': 'GITHUB',
        'Status': 'PENDING_HANDSHAKE'|'AVAILABLE'|'ERROR'|'DELETED',
        'CreatedAt': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --
    • Connection (dict) --

      A description of the App Runner connection that this request just deleted.

      • ConnectionName (string) --

        The customer-provided connection name.

      • ConnectionArn (string) --

        The Amazon Resource Name (ARN) of this connection.

      • ProviderType (string) --

        The source repository provider.

      • Status (string) --

        The current state of the App Runner connection. When the state is AVAILABLE , you can use the connection to create an App Runner service.

      • CreatedAt (datetime) --

        The App Runner connection creation time, expressed as a Unix time stamp.

Exceptions

delete_service(**kwargs)

Delete an App Runner service.

This is an asynchronous operation. On a successful call, you can use the returned OperationId and the ListOperations call to track the operation's progress.

See also: AWS API Documentation

Request Syntax

response = client.delete_service(
    ServiceArn='string'
)
Parameters
ServiceArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner service that you want to delete.

Return type
dict
Returns
Response Syntax
{
    'Service': {
        'ServiceName': 'string',
        'ServiceId': 'string',
        'ServiceArn': 'string',
        'ServiceUrl': 'string',
        'CreatedAt': datetime(2015, 1, 1),
        'UpdatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1),
        'Status': 'CREATE_FAILED'|'RUNNING'|'DELETED'|'DELETE_FAILED'|'PAUSED'|'OPERATION_IN_PROGRESS',
        'SourceConfiguration': {
            'CodeRepository': {
                'RepositoryUrl': 'string',
                'SourceCodeVersion': {
                    'Type': 'BRANCH',
                    'Value': 'string'
                },
                'CodeConfiguration': {
                    'ConfigurationSource': 'REPOSITORY'|'API',
                    'CodeConfigurationValues': {
                        'Runtime': 'PYTHON_3'|'NODEJS_12',
                        'BuildCommand': 'string',
                        'StartCommand': 'string',
                        'Port': 'string',
                        'RuntimeEnvironmentVariables': {
                            'string': 'string'
                        }
                    }
                }
            },
            'ImageRepository': {
                'ImageIdentifier': 'string',
                'ImageConfiguration': {
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    },
                    'StartCommand': 'string',
                    'Port': 'string'
                },
                'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
            },
            'AutoDeploymentsEnabled': True|False,
            'AuthenticationConfiguration': {
                'ConnectionArn': 'string',
                'AccessRoleArn': 'string'
            }
        },
        'InstanceConfiguration': {
            'Cpu': 'string',
            'Memory': 'string',
            'InstanceRoleArn': 'string'
        },
        'EncryptionConfiguration': {
            'KmsKey': 'string'
        },
        'HealthCheckConfiguration': {
            'Protocol': 'TCP'|'HTTP',
            'Path': 'string',
            'Interval': 123,
            'Timeout': 123,
            'HealthyThreshold': 123,
            'UnhealthyThreshold': 123
        },
        'AutoScalingConfigurationSummary': {
            'AutoScalingConfigurationArn': 'string',
            'AutoScalingConfigurationName': 'string',
            'AutoScalingConfigurationRevision': 123
        }
    },
    'OperationId': 'string'
}

Response Structure

  • (dict) --
    • Service (dict) --

      A description of the App Runner service that this request just deleted.

      • ServiceName (string) --

        The customer-provided service name.

      • ServiceId (string) --

        An ID that App Runner generated for this service. It's unique within the Amazon Web Services Region.

      • ServiceArn (string) --

        The Amazon Resource Name (ARN) of this service.

      • ServiceUrl (string) --

        A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.

      • CreatedAt (datetime) --

        The time when the App Runner service was created. It's in the Unix time stamp format.

      • UpdatedAt (datetime) --

        The time when the App Runner service was last updated at. It's in the Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the App Runner service was deleted. It's in the Unix time stamp format.

      • Status (string) --

        The current state of the App Runner service. These particular values mean the following.

        • CREATE_FAILED – The service failed to create. To troubleshoot this failure, read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn't usable, and still counts towards your service quota. When you're done analyzing the failure, delete the service.
        • DELETE_FAILED – The service failed to delete and can't be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
      • SourceConfiguration (dict) --

        The source deployed to the App Runner service. It can be a code or an image repository.

        • CodeRepository (dict) --

          The description of a source code repository.

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

          • RepositoryUrl (string) --

            The location of the repository that contains the source code.

          • SourceCodeVersion (dict) --

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

            • Type (string) --

              The type of version identifier.

              For a git-based repository, branches represent versions.

            • Value (string) --

              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.

          • CodeConfiguration (dict) --

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

            • ConfigurationSource (string) --

              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.
            • CodeConfigurationValues (dict) --

              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).

              • Runtime (string) --

                A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

              • BuildCommand (string) --

                The command App Runner runs to build your application.

              • StartCommand (string) --

                The command App Runner runs to start your application.

              • Port (string) --

                The port that your application listens to in the container.

                Default: 8080

              • RuntimeEnvironmentVariables (dict) --

                The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

                • (string) --
                  • (string) --
        • ImageRepository (dict) --

          The description of a source image repository.

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

          • ImageIdentifier (string) --

            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 .

          • ImageConfiguration (dict) --

            Configuration for running the identified image.

            • RuntimeEnvironmentVariables (dict) --

              Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

              • (string) --
                • (string) --
            • StartCommand (string) --

              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.

            • Port (string) --

              The port that your application listens to in the container.

              Default: 8080

          • ImageRepositoryType (string) --

            The type of the image repository. This reflects the repository provider and whether the repository is private or public.

        • AutoDeploymentsEnabled (boolean) --

          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 Amazon Web Services 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).

        • AuthenticationConfiguration (dict) --

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

          • ConnectionArn (string) --

            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.

          • AccessRoleArn (string) --

            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).

      • InstanceConfiguration (dict) --

        The runtime configuration of instances (scaling units) of this service.

        • Cpu (string) --

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

          Default: 1 vCPU

        • Memory (string) --

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

          Default: 2 GB

        • InstanceRoleArn (string) --

          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 Amazon Web Services APIs.

      • EncryptionConfiguration (dict) --

        The encryption key that App Runner uses to encrypt the service logs and the copy of the source repository that App Runner maintains for the service. It can be either a customer-provided encryption key or an Amazon Web Services managed CMK.

        • KmsKey (string) --

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

      • HealthCheckConfiguration (dict) --

        The settings for the health check that App Runner performs to monitor the health of this service.

        • Protocol (string) --

          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

        • Path (string) --

          The URL that health check requests are sent to.

          Path is only applicable when you set Protocol to HTTP .

          Default: "/"

        • Interval (integer) --

          The time interval, in seconds, between health checks.

          Default: 5

        • Timeout (integer) --

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

          Default: 2

        • HealthyThreshold (integer) --

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

          Default: 1

        • UnhealthyThreshold (integer) --

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

          Default: 5

      • AutoScalingConfigurationSummary (dict) --

        Summary information for the App Runner automatic scaling configuration resource that's associated with this service.

        • AutoScalingConfigurationArn (string) --

          The Amazon Resource Name (ARN) of this auto scaling configuration.

        • AutoScalingConfigurationName (string) --

          The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

        • AutoScalingConfigurationRevision (integer) --

          The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) with the same AutoScalingConfigurationName .

    • OperationId (string) --

      The unique ID of the asynchronous operation that this request started. You can use it combined with the ListOperations call to track the operation's progress.

Exceptions

describe_auto_scaling_configuration(**kwargs)

Return a full description of an App Runner automatic scaling configuration resource.

See also: AWS API Documentation

Request Syntax

response = client.describe_auto_scaling_configuration(
    AutoScalingConfigurationArn='string'
)
Parameters
AutoScalingConfigurationArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner auto scaling configuration that you want a description for.

The ARN can be a full auto scaling configuration ARN, or a partial ARN ending with either ``.../name `` or ``.../name /revision `` . If a revision isn't specified, the latest active revision is described.

Return type
dict
Returns
Response Syntax
{
    'AutoScalingConfiguration': {
        'AutoScalingConfigurationArn': 'string',
        'AutoScalingConfigurationName': 'string',
        'AutoScalingConfigurationRevision': 123,
        'Latest': True|False,
        'Status': 'ACTIVE'|'INACTIVE',
        'MaxConcurrency': 123,
        'MinSize': 123,
        'MaxSize': 123,
        'CreatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1)
    }
}

Response Structure

  • (dict) --
    • AutoScalingConfiguration (dict) --

      A full description of the App Runner auto scaling configuration that you specified in this request.

      • AutoScalingConfigurationArn (string) --

        The Amazon Resource Name (ARN) of this auto scaling configuration.

      • AutoScalingConfigurationName (string) --

        The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

      • AutoScalingConfigurationRevision (integer) --

        The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) that share the same AutoScalingConfigurationName .

      • Latest (boolean) --

        It's set to true for the configuration with the highest Revision among all configurations that share the same Name . It's set to false otherwise.

      • Status (string) --

        The current state of the auto scaling configuration. If the status of a configuration revision is INACTIVE , it was deleted and can't be used. Inactive configuration revisions are permanently removed some time after they are deleted.

      • MaxConcurrency (integer) --

        The maximum number of concurrent requests that an instance processes. If the number of concurrent requests exceeds this limit, App Runner scales the service up.

      • MinSize (integer) --

        The minimum number of instances that App Runner provisions for a service. The service always has at least MinSize provisioned instances. Some of them actively serve traffic. The rest of them (provisioned and inactive instances) are a cost-effective compute capacity reserve and are ready to be quickly activated. You pay for memory usage of all the provisioned instances. You pay for CPU usage of only the active subset.

        App Runner temporarily doubles the number of provisioned instances during deployments, to maintain the same capacity for both old and new code.

      • MaxSize (integer) --

        The maximum number of instances that a service scales up to. At most MaxSize instances actively serve traffic for your service.

      • CreatedAt (datetime) --

        The time when the auto scaling configuration was created. It's in Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the auto scaling configuration was deleted. It's in Unix time stamp format.

Exceptions

describe_custom_domains(**kwargs)

Return a description of custom domain names that are associated with an App Runner service.

See also: AWS API Documentation

Request Syntax

response = client.describe_custom_domains(
    ServiceArn='string',
    NextToken='string',
    MaxResults=123
)
Parameters
  • ServiceArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the App Runner service that you want associated custom domain names to be described for.

  • NextToken (string) --

    A token from a previous result page. It's used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones that are specified in the initial request.

    If you don't specify NextToken , the request retrieves the first result page.

  • MaxResults (integer) --

    The maximum number of results that each response (result page) can include. It's used for a paginated request.

    If you don't specify MaxResults , the request retrieves all available results in a single response.

Return type

dict

Returns

Response Syntax

{
    'DNSTarget': 'string',
    'ServiceArn': 'string',
    'CustomDomains': [
        {
            'DomainName': 'string',
            'EnableWWWSubdomain': True|False,
            'CertificateValidationRecords': [
                {
                    'Name': 'string',
                    'Type': 'string',
                    'Value': 'string',
                    'Status': 'PENDING_VALIDATION'|'SUCCESS'|'FAILED'
                },
            ],
            'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'DELETING'|'DELETE_FAILED'|'PENDING_CERTIFICATE_DNS_VALIDATION'|'BINDING_CERTIFICATE'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • DNSTarget (string) --

      The App Runner subdomain of the App Runner service. The associated custom domain names are mapped to this target name.

    • ServiceArn (string) --

      The Amazon Resource Name (ARN) of the App Runner service whose associated custom domain names you want to describe.

    • CustomDomains (list) --

      A list of descriptions of custom domain names that are associated with the service. In a paginated request, the request returns up to MaxResults records per call.

      • (dict) --

        Describes a custom domain that's associated with an App Runner service.

        • DomainName (string) --

          An associated custom domain endpoint. It can be a root domain (for example, example.com ), a subdomain (for example, login.example.com or admin.login.example.com ), or a wildcard (for example, *.example.com ).

        • EnableWWWSubdomain (boolean) --

          When true , the subdomain ``www.*DomainName* `` is associated with the App Runner service in addition to the base domain.

        • CertificateValidationRecords (list) --

          A list of certificate CNAME records that's used for this domain name.

          • (dict) --

            Describes a certificate CNAME record to add to your DNS. For more information, see AssociateCustomDomain .

            • Name (string) --

              The certificate CNAME record name.

            • Type (string) --

              The record type, always CNAME .

            • Value (string) --

              The certificate CNAME record value.

            • Status (string) --

              The current state of the certificate CNAME record validation. It should change to SUCCESS after App Runner completes validation with your DNS.

        • Status (string) --

          The current state of the domain name association.

    • NextToken (string) --

      The token that you can pass in a subsequent request to get the next result page. It's returned in a paginated request.

Exceptions

describe_service(**kwargs)

Return a full description of an App Runner service.

See also: AWS API Documentation

Request Syntax

response = client.describe_service(
    ServiceArn='string'
)
Parameters
ServiceArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner service that you want a description for.

Return type
dict
Returns
Response Syntax
{
    'Service': {
        'ServiceName': 'string',
        'ServiceId': 'string',
        'ServiceArn': 'string',
        'ServiceUrl': 'string',
        'CreatedAt': datetime(2015, 1, 1),
        'UpdatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1),
        'Status': 'CREATE_FAILED'|'RUNNING'|'DELETED'|'DELETE_FAILED'|'PAUSED'|'OPERATION_IN_PROGRESS',
        'SourceConfiguration': {
            'CodeRepository': {
                'RepositoryUrl': 'string',
                'SourceCodeVersion': {
                    'Type': 'BRANCH',
                    'Value': 'string'
                },
                'CodeConfiguration': {
                    'ConfigurationSource': 'REPOSITORY'|'API',
                    'CodeConfigurationValues': {
                        'Runtime': 'PYTHON_3'|'NODEJS_12',
                        'BuildCommand': 'string',
                        'StartCommand': 'string',
                        'Port': 'string',
                        'RuntimeEnvironmentVariables': {
                            'string': 'string'
                        }
                    }
                }
            },
            'ImageRepository': {
                'ImageIdentifier': 'string',
                'ImageConfiguration': {
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    },
                    'StartCommand': 'string',
                    'Port': 'string'
                },
                'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
            },
            'AutoDeploymentsEnabled': True|False,
            'AuthenticationConfiguration': {
                'ConnectionArn': 'string',
                'AccessRoleArn': 'string'
            }
        },
        'InstanceConfiguration': {
            'Cpu': 'string',
            'Memory': 'string',
            'InstanceRoleArn': 'string'
        },
        'EncryptionConfiguration': {
            'KmsKey': 'string'
        },
        'HealthCheckConfiguration': {
            'Protocol': 'TCP'|'HTTP',
            'Path': 'string',
            'Interval': 123,
            'Timeout': 123,
            'HealthyThreshold': 123,
            'UnhealthyThreshold': 123
        },
        'AutoScalingConfigurationSummary': {
            'AutoScalingConfigurationArn': 'string',
            'AutoScalingConfigurationName': 'string',
            'AutoScalingConfigurationRevision': 123
        }
    }
}

Response Structure

  • (dict) --
    • Service (dict) --

      A full description of the App Runner service that you specified in this request.

      • ServiceName (string) --

        The customer-provided service name.

      • ServiceId (string) --

        An ID that App Runner generated for this service. It's unique within the Amazon Web Services Region.

      • ServiceArn (string) --

        The Amazon Resource Name (ARN) of this service.

      • ServiceUrl (string) --

        A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.

      • CreatedAt (datetime) --

        The time when the App Runner service was created. It's in the Unix time stamp format.

      • UpdatedAt (datetime) --

        The time when the App Runner service was last updated at. It's in the Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the App Runner service was deleted. It's in the Unix time stamp format.

      • Status (string) --

        The current state of the App Runner service. These particular values mean the following.

        • CREATE_FAILED – The service failed to create. To troubleshoot this failure, read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn't usable, and still counts towards your service quota. When you're done analyzing the failure, delete the service.
        • DELETE_FAILED – The service failed to delete and can't be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
      • SourceConfiguration (dict) --

        The source deployed to the App Runner service. It can be a code or an image repository.

        • CodeRepository (dict) --

          The description of a source code repository.

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

          • RepositoryUrl (string) --

            The location of the repository that contains the source code.

          • SourceCodeVersion (dict) --

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

            • Type (string) --

              The type of version identifier.

              For a git-based repository, branches represent versions.

            • Value (string) --

              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.

          • CodeConfiguration (dict) --

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

            • ConfigurationSource (string) --

              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.
            • CodeConfigurationValues (dict) --

              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).

              • Runtime (string) --

                A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

              • BuildCommand (string) --

                The command App Runner runs to build your application.

              • StartCommand (string) --

                The command App Runner runs to start your application.

              • Port (string) --

                The port that your application listens to in the container.

                Default: 8080

              • RuntimeEnvironmentVariables (dict) --

                The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

                • (string) --
                  • (string) --
        • ImageRepository (dict) --

          The description of a source image repository.

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

          • ImageIdentifier (string) --

            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 .

          • ImageConfiguration (dict) --

            Configuration for running the identified image.

            • RuntimeEnvironmentVariables (dict) --

              Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

              • (string) --
                • (string) --
            • StartCommand (string) --

              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.

            • Port (string) --

              The port that your application listens to in the container.

              Default: 8080

          • ImageRepositoryType (string) --

            The type of the image repository. This reflects the repository provider and whether the repository is private or public.

        • AutoDeploymentsEnabled (boolean) --

          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 Amazon Web Services 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).

        • AuthenticationConfiguration (dict) --

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

          • ConnectionArn (string) --

            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.

          • AccessRoleArn (string) --

            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).

      • InstanceConfiguration (dict) --

        The runtime configuration of instances (scaling units) of this service.

        • Cpu (string) --

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

          Default: 1 vCPU

        • Memory (string) --

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

          Default: 2 GB

        • InstanceRoleArn (string) --

          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 Amazon Web Services APIs.

      • EncryptionConfiguration (dict) --

        The encryption key that App Runner uses to encrypt the service logs and the copy of the source repository that App Runner maintains for the service. It can be either a customer-provided encryption key or an Amazon Web Services managed CMK.

        • KmsKey (string) --

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

      • HealthCheckConfiguration (dict) --

        The settings for the health check that App Runner performs to monitor the health of this service.

        • Protocol (string) --

          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

        • Path (string) --

          The URL that health check requests are sent to.

          Path is only applicable when you set Protocol to HTTP .

          Default: "/"

        • Interval (integer) --

          The time interval, in seconds, between health checks.

          Default: 5

        • Timeout (integer) --

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

          Default: 2

        • HealthyThreshold (integer) --

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

          Default: 1

        • UnhealthyThreshold (integer) --

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

          Default: 5

      • AutoScalingConfigurationSummary (dict) --

        Summary information for the App Runner automatic scaling configuration resource that's associated with this service.

        • AutoScalingConfigurationArn (string) --

          The Amazon Resource Name (ARN) of this auto scaling configuration.

        • AutoScalingConfigurationName (string) --

          The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

        • AutoScalingConfigurationRevision (integer) --

          The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) with the same AutoScalingConfigurationName .

Exceptions

disassociate_custom_domain(**kwargs)

Disassociate a custom domain name from an App Runner service.

Certificates tracking domain validity are associated with a custom domain and are stored in AWS Certificate Manager (ACM) . These certificates aren't deleted as part of this action. App Runner delays certificate deletion for 30 days after a domain is disassociated from your service.

See also: AWS API Documentation

Request Syntax

response = client.disassociate_custom_domain(
    ServiceArn='string',
    DomainName='string'
)
Parameters
  • ServiceArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the App Runner service that you want to disassociate a custom domain name from.

  • DomainName (string) --

    [REQUIRED]

    The domain name that you want to disassociate from the App Runner service.

Return type

dict

Returns

Response Syntax

{
    'DNSTarget': 'string',
    'ServiceArn': 'string',
    'CustomDomain': {
        'DomainName': 'string',
        'EnableWWWSubdomain': True|False,
        'CertificateValidationRecords': [
            {
                'Name': 'string',
                'Type': 'string',
                'Value': 'string',
                'Status': 'PENDING_VALIDATION'|'SUCCESS'|'FAILED'
            },
        ],
        'Status': 'CREATING'|'CREATE_FAILED'|'ACTIVE'|'DELETING'|'DELETE_FAILED'|'PENDING_CERTIFICATE_DNS_VALIDATION'|'BINDING_CERTIFICATE'
    }
}

Response Structure

  • (dict) --

    • DNSTarget (string) --

      The App Runner subdomain of the App Runner service. The disassociated custom domain name was mapped to this target name.

    • ServiceArn (string) --

      The Amazon Resource Name (ARN) of the App Runner service that a custom domain name is disassociated from.

    • CustomDomain (dict) --

      A description of the domain name that's being disassociated.

      • DomainName (string) --

        An associated custom domain endpoint. It can be a root domain (for example, example.com ), a subdomain (for example, login.example.com or admin.login.example.com ), or a wildcard (for example, *.example.com ).

      • EnableWWWSubdomain (boolean) --

        When true , the subdomain ``www.*DomainName* `` is associated with the App Runner service in addition to the base domain.

      • CertificateValidationRecords (list) --

        A list of certificate CNAME records that's used for this domain name.

        • (dict) --

          Describes a certificate CNAME record to add to your DNS. For more information, see AssociateCustomDomain .

          • Name (string) --

            The certificate CNAME record name.

          • Type (string) --

            The record type, always CNAME .

          • Value (string) --

            The certificate CNAME record value.

          • Status (string) --

            The current state of the certificate CNAME record validation. It should change to SUCCESS after App Runner completes validation with your DNS.

      • Status (string) --

        The current state of the domain name association.

Exceptions

generate_presigned_url(ClientMethod, Params=None, ExpiresIn=3600, HttpMethod=None)

Generate a presigned url given a client, its method, and arguments

Parameters
  • ClientMethod (string) -- The client method to presign for
  • Params (dict) -- The parameters normally passed to ClientMethod.
  • ExpiresIn (int) -- The number of seconds the presigned url is valid for. By default it expires in an hour (3600 seconds)
  • HttpMethod (string) -- The http method to use on the generated url. By default, the http method is whatever is used in the method's model.
Returns

The presigned url

get_paginator(operation_name)

Create a paginator for an operation.

Parameters
operation_name (string) -- The operation name. This is the same name as the method name on the client. For example, if the method name is create_foo, and you'd normally invoke the operation as client.create_foo(**kwargs), if the create_foo operation can be paginated, you can use the call client.get_paginator("create_foo").
Raises OperationNotPageableError
Raised if the operation is not pageable. You can use the client.can_paginate method to check if an operation is pageable.
Return type
L{botocore.paginate.Paginator}
Returns
A paginator object.
get_waiter(waiter_name)

Returns an object that can wait for some condition.

Parameters
waiter_name (str) -- The name of the waiter to get. See the waiters section of the service docs for a list of available waiters.
Returns
The specified waiter object.
Return type
botocore.waiter.Waiter
list_auto_scaling_configurations(**kwargs)

Returns a list of App Runner automatic scaling configurations in your Amazon Web Services account. You can query the revisions for a specific configuration name or the revisions for all configurations in your account. You can optionally query only the latest revision of each requested name.

See also: AWS API Documentation

Request Syntax

response = client.list_auto_scaling_configurations(
    AutoScalingConfigurationName='string',
    LatestOnly=True|False,
    MaxResults=123,
    NextToken='string'
)
Parameters
  • AutoScalingConfigurationName (string) -- The name of the App Runner auto scaling configuration that you want to list. If specified, App Runner lists revisions that share this name. If not specified, App Runner returns revisions of all configurations.
  • LatestOnly (boolean) --

    Set to true to list only the latest revision for each requested configuration name.

    Keep as false to list all revisions for each requested configuration name.

    Default: false

  • MaxResults (integer) --

    The maximum number of results to include in each response (result page). It's used for a paginated request.

    If you don't specify MaxResults , the request retrieves all available results in a single response.

  • NextToken (string) --

    A token from a previous result page. It's used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones that are specified in the initial request.

    If you don't specify NextToken , the request retrieves the first result page.

Return type

dict

Returns

Response Syntax

{
    'AutoScalingConfigurationSummaryList': [
        {
            'AutoScalingConfigurationArn': 'string',
            'AutoScalingConfigurationName': 'string',
            'AutoScalingConfigurationRevision': 123
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • AutoScalingConfigurationSummaryList (list) --

      A list of summary information records for auto scaling configurations. In a paginated request, the request returns up to MaxResults records for each call.

      • (dict) --

        Provides summary information about an App Runner automatic scaling configuration resource.

        This type contains limited information about an auto scaling configuration. It includes only identification information, without configuration details. It's returned by the ListAutoScalingConfigurations action. Complete configuration information is returned by the CreateAutoScalingConfiguration , DescribeAutoScalingConfiguration , and DeleteAutoScalingConfiguration actions using the AutoScalingConfiguration type.

        • AutoScalingConfigurationArn (string) --

          The Amazon Resource Name (ARN) of this auto scaling configuration.

        • AutoScalingConfigurationName (string) --

          The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

        • AutoScalingConfigurationRevision (integer) --

          The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) with the same AutoScalingConfigurationName .

    • NextToken (string) --

      The token that you can pass in a subsequent request to get the next result page. It's returned in a paginated request.

Exceptions

list_connections(**kwargs)

Returns a list of App Runner connections that are associated with your Amazon Web Services account.

See also: AWS API Documentation

Request Syntax

response = client.list_connections(
    ConnectionName='string',
    MaxResults=123,
    NextToken='string'
)
Parameters
  • ConnectionName (string) -- If specified, only this connection is returned. If not specified, the result isn't filtered by name.
  • MaxResults (integer) --

    The maximum number of results to include in each response (result page). Used for a paginated request.

    If you don't specify MaxResults , the request retrieves all available results in a single response.

  • NextToken (string) --

    A token from a previous result page. Used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones specified in the initial request.

    If you don't specify NextToken , the request retrieves the first result page.

Return type

dict

Returns

Response Syntax

{
    'ConnectionSummaryList': [
        {
            'ConnectionName': 'string',
            'ConnectionArn': 'string',
            'ProviderType': 'GITHUB',
            'Status': 'PENDING_HANDSHAKE'|'AVAILABLE'|'ERROR'|'DELETED',
            'CreatedAt': datetime(2015, 1, 1)
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • ConnectionSummaryList (list) --

      A list of summary information records for connections. In a paginated request, the request returns up to MaxResults records for each call.

      • (dict) --

        Provides summary information about an App Runner connection resource.

        • ConnectionName (string) --

          The customer-provided connection name.

        • ConnectionArn (string) --

          The Amazon Resource Name (ARN) of this connection.

        • ProviderType (string) --

          The source repository provider.

        • Status (string) --

          The current state of the App Runner connection. When the state is AVAILABLE , you can use the connection to create an App Runner service.

        • CreatedAt (datetime) --

          The App Runner connection creation time, expressed as a Unix time stamp.

    • NextToken (string) --

      The token that you can pass in a subsequent request to get the next result page. Returned in a paginated request.

Exceptions

list_operations(**kwargs)

Return a list of operations that occurred on an App Runner service.

The resulting list of OperationSummary objects is sorted in reverse chronological order. The first object on the list represents the last started operation.

See also: AWS API Documentation

Request Syntax

response = client.list_operations(
    ServiceArn='string',
    NextToken='string',
    MaxResults=123
)
Parameters
  • ServiceArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the App Runner service that you want a list of operations for.

  • NextToken (string) --

    A token from a previous result page. It's used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones specified in the initial request.

    If you don't specify NextToken , the request retrieves the first result page.

  • MaxResults (integer) --

    The maximum number of results to include in each response (result page). It's used for a paginated request.

    If you don't specify MaxResults , the request retrieves all available results in a single response.

Return type

dict

Returns

Response Syntax

{
    'OperationSummaryList': [
        {
            'Id': 'string',
            'Type': 'START_DEPLOYMENT'|'CREATE_SERVICE'|'PAUSE_SERVICE'|'RESUME_SERVICE'|'DELETE_SERVICE',
            'Status': 'PENDING'|'IN_PROGRESS'|'FAILED'|'SUCCEEDED'|'ROLLBACK_IN_PROGRESS'|'ROLLBACK_FAILED'|'ROLLBACK_SUCCEEDED',
            'TargetArn': 'string',
            'StartedAt': datetime(2015, 1, 1),
            'EndedAt': datetime(2015, 1, 1),
            'UpdatedAt': datetime(2015, 1, 1)
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • OperationSummaryList (list) --

      A list of operation summary information records. In a paginated request, the request returns up to MaxResults records for each call.

      • (dict) --

        Provides summary information for an operation that occurred on an App Runner service.

        • Id (string) --

          A unique ID of this operation. It's unique in the scope of the App Runner service.

        • Type (string) --

          The type of operation. It indicates a specific action that occured.

        • Status (string) --

          The current state of the operation.

        • TargetArn (string) --

          The Amazon Resource Name (ARN) of the resource that the operation acted on (for example, an App Runner service).

        • StartedAt (datetime) --

          The time when the operation started. It's in the Unix time stamp format.

        • EndedAt (datetime) --

          The time when the operation ended. It's in the Unix time stamp format.

        • UpdatedAt (datetime) --

          The time when the operation was last updated. It's in the Unix time stamp format.

    • NextToken (string) --

      The token that you can pass in a subsequent request to get the next result page. It's returned in a paginated request.

Exceptions

list_services(**kwargs)

Returns a list of running App Runner services in your Amazon Web Services account.

See also: AWS API Documentation

Request Syntax

response = client.list_services(
    NextToken='string',
    MaxResults=123
)
Parameters
  • NextToken (string) --

    A token from a previous result page. Used for a paginated request. The request retrieves the next result page. All other parameter values must be identical to the ones specified in the initial request.

    If you don't specify NextToken , the request retrieves the first result page.

  • MaxResults (integer) --

    The maximum number of results to include in each response (result page). It's used for a paginated request.

    If you don't specify MaxResults , the request retrieves all available results in a single response.

Return type

dict

Returns

Response Syntax

{
    'ServiceSummaryList': [
        {
            'ServiceName': 'string',
            'ServiceId': 'string',
            'ServiceArn': 'string',
            'ServiceUrl': 'string',
            'CreatedAt': datetime(2015, 1, 1),
            'UpdatedAt': datetime(2015, 1, 1),
            'Status': 'CREATE_FAILED'|'RUNNING'|'DELETED'|'DELETE_FAILED'|'PAUSED'|'OPERATION_IN_PROGRESS'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • ServiceSummaryList (list) --

      A list of service summary information records. In a paginated request, the request returns up to MaxResults records for each call.

      • (dict) --

        Provides summary information for an App Runner service.

        This type contains limited information about a service. It doesn't include configuration details. It's returned by the ListServices action. Complete service information is returned by the CreateService , DescribeService , and DeleteService actions using the Service type.

        • ServiceName (string) --

          The customer-provided service name.

        • ServiceId (string) --

          An ID that App Runner generated for this service. It's unique within the Amazon Web Services Region.

        • ServiceArn (string) --

          The Amazon Resource Name (ARN) of this service.

        • ServiceUrl (string) --

          A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.

        • CreatedAt (datetime) --

          The time when the App Runner service was created. It's in the Unix time stamp format.

        • UpdatedAt (datetime) --

          The time when the App Runner service was last updated. It's in theUnix time stamp format.

        • Status (string) --

          The current state of the App Runner service. These particular values mean the following.

          • CREATE_FAILED – The service failed to create. Read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn't usable, and still counts towards your service quota. When you're done analyzing the failure, delete the service.
          • DELETE_FAILED – The service failed to delete and can't be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
    • NextToken (string) --

      The token that you can pass in a subsequent request to get the next result page. It's returned in a paginated request.

Exceptions

list_tags_for_resource(**kwargs)

List tags that are associated with for an App Runner resource. The response contains a list of tag key-value pairs.

See also: AWS API Documentation

Request Syntax

response = client.list_tags_for_resource(
    ResourceArn='string'
)
Parameters
ResourceArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the resource that a tag list is requested for.

It must be the ARN of an App Runner resource.

Return type
dict
Returns
Response Syntax
{
    'Tags': [
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
}

Response Structure

  • (dict) --
    • Tags (list) --

      A list of the tag key-value pairs that are associated with the resource.

      • (dict) --

        Describes a tag that is applied to an App Runner resource. A tag is a metadata item consisting of a key-value pair.

        • Key (string) --

          The key of the tag.

        • Value (string) --

          The value of the tag.

Exceptions

pause_service(**kwargs)

Pause an active App Runner service. App Runner reduces compute capacity for the service to zero and loses state (for example, ephemeral storage is removed).

This is an asynchronous operation. On a successful call, you can use the returned OperationId and the ListOperations call to track the operation's progress.

See also: AWS API Documentation

Request Syntax

response = client.pause_service(
    ServiceArn='string'
)
Parameters
ServiceArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner service that you want to pause.

Return type
dict
Returns
Response Syntax
{
    'Service': {
        'ServiceName': 'string',
        'ServiceId': 'string',
        'ServiceArn': 'string',
        'ServiceUrl': 'string',
        'CreatedAt': datetime(2015, 1, 1),
        'UpdatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1),
        'Status': 'CREATE_FAILED'|'RUNNING'|'DELETED'|'DELETE_FAILED'|'PAUSED'|'OPERATION_IN_PROGRESS',
        'SourceConfiguration': {
            'CodeRepository': {
                'RepositoryUrl': 'string',
                'SourceCodeVersion': {
                    'Type': 'BRANCH',
                    'Value': 'string'
                },
                'CodeConfiguration': {
                    'ConfigurationSource': 'REPOSITORY'|'API',
                    'CodeConfigurationValues': {
                        'Runtime': 'PYTHON_3'|'NODEJS_12',
                        'BuildCommand': 'string',
                        'StartCommand': 'string',
                        'Port': 'string',
                        'RuntimeEnvironmentVariables': {
                            'string': 'string'
                        }
                    }
                }
            },
            'ImageRepository': {
                'ImageIdentifier': 'string',
                'ImageConfiguration': {
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    },
                    'StartCommand': 'string',
                    'Port': 'string'
                },
                'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
            },
            'AutoDeploymentsEnabled': True|False,
            'AuthenticationConfiguration': {
                'ConnectionArn': 'string',
                'AccessRoleArn': 'string'
            }
        },
        'InstanceConfiguration': {
            'Cpu': 'string',
            'Memory': 'string',
            'InstanceRoleArn': 'string'
        },
        'EncryptionConfiguration': {
            'KmsKey': 'string'
        },
        'HealthCheckConfiguration': {
            'Protocol': 'TCP'|'HTTP',
            'Path': 'string',
            'Interval': 123,
            'Timeout': 123,
            'HealthyThreshold': 123,
            'UnhealthyThreshold': 123
        },
        'AutoScalingConfigurationSummary': {
            'AutoScalingConfigurationArn': 'string',
            'AutoScalingConfigurationName': 'string',
            'AutoScalingConfigurationRevision': 123
        }
    },
    'OperationId': 'string'
}

Response Structure

  • (dict) --
    • Service (dict) --

      A description of the App Runner service that this request just paused.

      • ServiceName (string) --

        The customer-provided service name.

      • ServiceId (string) --

        An ID that App Runner generated for this service. It's unique within the Amazon Web Services Region.

      • ServiceArn (string) --

        The Amazon Resource Name (ARN) of this service.

      • ServiceUrl (string) --

        A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.

      • CreatedAt (datetime) --

        The time when the App Runner service was created. It's in the Unix time stamp format.

      • UpdatedAt (datetime) --

        The time when the App Runner service was last updated at. It's in the Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the App Runner service was deleted. It's in the Unix time stamp format.

      • Status (string) --

        The current state of the App Runner service. These particular values mean the following.

        • CREATE_FAILED – The service failed to create. To troubleshoot this failure, read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn't usable, and still counts towards your service quota. When you're done analyzing the failure, delete the service.
        • DELETE_FAILED – The service failed to delete and can't be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
      • SourceConfiguration (dict) --

        The source deployed to the App Runner service. It can be a code or an image repository.

        • CodeRepository (dict) --

          The description of a source code repository.

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

          • RepositoryUrl (string) --

            The location of the repository that contains the source code.

          • SourceCodeVersion (dict) --

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

            • Type (string) --

              The type of version identifier.

              For a git-based repository, branches represent versions.

            • Value (string) --

              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.

          • CodeConfiguration (dict) --

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

            • ConfigurationSource (string) --

              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.
            • CodeConfigurationValues (dict) --

              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).

              • Runtime (string) --

                A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

              • BuildCommand (string) --

                The command App Runner runs to build your application.

              • StartCommand (string) --

                The command App Runner runs to start your application.

              • Port (string) --

                The port that your application listens to in the container.

                Default: 8080

              • RuntimeEnvironmentVariables (dict) --

                The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

                • (string) --
                  • (string) --
        • ImageRepository (dict) --

          The description of a source image repository.

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

          • ImageIdentifier (string) --

            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 .

          • ImageConfiguration (dict) --

            Configuration for running the identified image.

            • RuntimeEnvironmentVariables (dict) --

              Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

              • (string) --
                • (string) --
            • StartCommand (string) --

              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.

            • Port (string) --

              The port that your application listens to in the container.

              Default: 8080

          • ImageRepositoryType (string) --

            The type of the image repository. This reflects the repository provider and whether the repository is private or public.

        • AutoDeploymentsEnabled (boolean) --

          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 Amazon Web Services 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).

        • AuthenticationConfiguration (dict) --

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

          • ConnectionArn (string) --

            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.

          • AccessRoleArn (string) --

            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).

      • InstanceConfiguration (dict) --

        The runtime configuration of instances (scaling units) of this service.

        • Cpu (string) --

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

          Default: 1 vCPU

        • Memory (string) --

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

          Default: 2 GB

        • InstanceRoleArn (string) --

          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 Amazon Web Services APIs.

      • EncryptionConfiguration (dict) --

        The encryption key that App Runner uses to encrypt the service logs and the copy of the source repository that App Runner maintains for the service. It can be either a customer-provided encryption key or an Amazon Web Services managed CMK.

        • KmsKey (string) --

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

      • HealthCheckConfiguration (dict) --

        The settings for the health check that App Runner performs to monitor the health of this service.

        • Protocol (string) --

          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

        • Path (string) --

          The URL that health check requests are sent to.

          Path is only applicable when you set Protocol to HTTP .

          Default: "/"

        • Interval (integer) --

          The time interval, in seconds, between health checks.

          Default: 5

        • Timeout (integer) --

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

          Default: 2

        • HealthyThreshold (integer) --

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

          Default: 1

        • UnhealthyThreshold (integer) --

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

          Default: 5

      • AutoScalingConfigurationSummary (dict) --

        Summary information for the App Runner automatic scaling configuration resource that's associated with this service.

        • AutoScalingConfigurationArn (string) --

          The Amazon Resource Name (ARN) of this auto scaling configuration.

        • AutoScalingConfigurationName (string) --

          The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

        • AutoScalingConfigurationRevision (integer) --

          The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) with the same AutoScalingConfigurationName .

    • OperationId (string) --

      The unique ID of the asynchronous operation that this request started. You can use it combined with the ListOperations call to track the operation's progress.

Exceptions

resume_service(**kwargs)

Resume an active App Runner service. App Runner provisions compute capacity for the service.

This is an asynchronous operation. On a successful call, you can use the returned OperationId and the ListOperations call to track the operation's progress.

See also: AWS API Documentation

Request Syntax

response = client.resume_service(
    ServiceArn='string'
)
Parameters
ServiceArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner service that you want to resume.

Return type
dict
Returns
Response Syntax
{
    'Service': {
        'ServiceName': 'string',
        'ServiceId': 'string',
        'ServiceArn': 'string',
        'ServiceUrl': 'string',
        'CreatedAt': datetime(2015, 1, 1),
        'UpdatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1),
        'Status': 'CREATE_FAILED'|'RUNNING'|'DELETED'|'DELETE_FAILED'|'PAUSED'|'OPERATION_IN_PROGRESS',
        'SourceConfiguration': {
            'CodeRepository': {
                'RepositoryUrl': 'string',
                'SourceCodeVersion': {
                    'Type': 'BRANCH',
                    'Value': 'string'
                },
                'CodeConfiguration': {
                    'ConfigurationSource': 'REPOSITORY'|'API',
                    'CodeConfigurationValues': {
                        'Runtime': 'PYTHON_3'|'NODEJS_12',
                        'BuildCommand': 'string',
                        'StartCommand': 'string',
                        'Port': 'string',
                        'RuntimeEnvironmentVariables': {
                            'string': 'string'
                        }
                    }
                }
            },
            'ImageRepository': {
                'ImageIdentifier': 'string',
                'ImageConfiguration': {
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    },
                    'StartCommand': 'string',
                    'Port': 'string'
                },
                'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
            },
            'AutoDeploymentsEnabled': True|False,
            'AuthenticationConfiguration': {
                'ConnectionArn': 'string',
                'AccessRoleArn': 'string'
            }
        },
        'InstanceConfiguration': {
            'Cpu': 'string',
            'Memory': 'string',
            'InstanceRoleArn': 'string'
        },
        'EncryptionConfiguration': {
            'KmsKey': 'string'
        },
        'HealthCheckConfiguration': {
            'Protocol': 'TCP'|'HTTP',
            'Path': 'string',
            'Interval': 123,
            'Timeout': 123,
            'HealthyThreshold': 123,
            'UnhealthyThreshold': 123
        },
        'AutoScalingConfigurationSummary': {
            'AutoScalingConfigurationArn': 'string',
            'AutoScalingConfigurationName': 'string',
            'AutoScalingConfigurationRevision': 123
        }
    },
    'OperationId': 'string'
}

Response Structure

  • (dict) --
    • Service (dict) --

      A description of the App Runner service that this request just resumed.

      • ServiceName (string) --

        The customer-provided service name.

      • ServiceId (string) --

        An ID that App Runner generated for this service. It's unique within the Amazon Web Services Region.

      • ServiceArn (string) --

        The Amazon Resource Name (ARN) of this service.

      • ServiceUrl (string) --

        A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.

      • CreatedAt (datetime) --

        The time when the App Runner service was created. It's in the Unix time stamp format.

      • UpdatedAt (datetime) --

        The time when the App Runner service was last updated at. It's in the Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the App Runner service was deleted. It's in the Unix time stamp format.

      • Status (string) --

        The current state of the App Runner service. These particular values mean the following.

        • CREATE_FAILED – The service failed to create. To troubleshoot this failure, read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn't usable, and still counts towards your service quota. When you're done analyzing the failure, delete the service.
        • DELETE_FAILED – The service failed to delete and can't be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
      • SourceConfiguration (dict) --

        The source deployed to the App Runner service. It can be a code or an image repository.

        • CodeRepository (dict) --

          The description of a source code repository.

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

          • RepositoryUrl (string) --

            The location of the repository that contains the source code.

          • SourceCodeVersion (dict) --

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

            • Type (string) --

              The type of version identifier.

              For a git-based repository, branches represent versions.

            • Value (string) --

              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.

          • CodeConfiguration (dict) --

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

            • ConfigurationSource (string) --

              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.
            • CodeConfigurationValues (dict) --

              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).

              • Runtime (string) --

                A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

              • BuildCommand (string) --

                The command App Runner runs to build your application.

              • StartCommand (string) --

                The command App Runner runs to start your application.

              • Port (string) --

                The port that your application listens to in the container.

                Default: 8080

              • RuntimeEnvironmentVariables (dict) --

                The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

                • (string) --
                  • (string) --
        • ImageRepository (dict) --

          The description of a source image repository.

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

          • ImageIdentifier (string) --

            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 .

          • ImageConfiguration (dict) --

            Configuration for running the identified image.

            • RuntimeEnvironmentVariables (dict) --

              Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

              • (string) --
                • (string) --
            • StartCommand (string) --

              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.

            • Port (string) --

              The port that your application listens to in the container.

              Default: 8080

          • ImageRepositoryType (string) --

            The type of the image repository. This reflects the repository provider and whether the repository is private or public.

        • AutoDeploymentsEnabled (boolean) --

          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 Amazon Web Services 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).

        • AuthenticationConfiguration (dict) --

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

          • ConnectionArn (string) --

            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.

          • AccessRoleArn (string) --

            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).

      • InstanceConfiguration (dict) --

        The runtime configuration of instances (scaling units) of this service.

        • Cpu (string) --

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

          Default: 1 vCPU

        • Memory (string) --

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

          Default: 2 GB

        • InstanceRoleArn (string) --

          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 Amazon Web Services APIs.

      • EncryptionConfiguration (dict) --

        The encryption key that App Runner uses to encrypt the service logs and the copy of the source repository that App Runner maintains for the service. It can be either a customer-provided encryption key or an Amazon Web Services managed CMK.

        • KmsKey (string) --

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

      • HealthCheckConfiguration (dict) --

        The settings for the health check that App Runner performs to monitor the health of this service.

        • Protocol (string) --

          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

        • Path (string) --

          The URL that health check requests are sent to.

          Path is only applicable when you set Protocol to HTTP .

          Default: "/"

        • Interval (integer) --

          The time interval, in seconds, between health checks.

          Default: 5

        • Timeout (integer) --

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

          Default: 2

        • HealthyThreshold (integer) --

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

          Default: 1

        • UnhealthyThreshold (integer) --

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

          Default: 5

      • AutoScalingConfigurationSummary (dict) --

        Summary information for the App Runner automatic scaling configuration resource that's associated with this service.

        • AutoScalingConfigurationArn (string) --

          The Amazon Resource Name (ARN) of this auto scaling configuration.

        • AutoScalingConfigurationName (string) --

          The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

        • AutoScalingConfigurationRevision (integer) --

          The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) with the same AutoScalingConfigurationName .

    • OperationId (string) --

      The unique ID of the asynchronous operation that this request started. You can use it combined with the ListOperations call to track the operation's progress.

Exceptions

start_deployment(**kwargs)

Initiate a manual deployment of the latest commit in a source code repository or the latest image in a source image repository to an App Runner service.

For a source code repository, App Runner retrieves the commit and builds a Docker image. For a source image repository, App Runner retrieves the latest Docker image. In both cases, App Runner then deploys the new image to your service and starts a new container instance.

This is an asynchronous operation. On a successful call, you can use the returned OperationId and the ListOperations call to track the operation's progress.

See also: AWS API Documentation

Request Syntax

response = client.start_deployment(
    ServiceArn='string'
)
Parameters
ServiceArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the App Runner service that you want to manually deploy to.

Return type
dict
Returns
Response Syntax
{
    'OperationId': 'string'
}

Response Structure

  • (dict) --
    • OperationId (string) --

      The unique ID of the asynchronous operation that this request started. You can use it combined with the ListOperations call to track the operation's progress.

Exceptions

tag_resource(**kwargs)

Add tags to, or update the tag values of, an App Runner resource. A tag is a key-value pair.

See also: AWS API Documentation

Request Syntax

response = client.tag_resource(
    ResourceArn='string',
    Tags=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ]
)
Parameters
  • ResourceArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the resource that you want to update tags for.

    It must be the ARN of an App Runner resource.

  • Tags (list) --

    [REQUIRED]

    A list of tag key-value pairs to add or update. If a key is new to the resource, the tag is added with the provided value. If a key is already associated with the resource, the value of the tag is updated.

    • (dict) --

      Describes a tag that is applied to an App Runner resource. A tag is a metadata item consisting of a key-value pair.

      • Key (string) --

        The key of the tag.

      • Value (string) --

        The value of the tag.

Return type

dict

Returns

Response Syntax

{}

Response Structure

  • (dict) --

Exceptions

untag_resource(**kwargs)

Remove tags from an App Runner resource.

See also: AWS API Documentation

Request Syntax

response = client.untag_resource(
    ResourceArn='string',
    TagKeys=[
        'string',
    ]
)
Parameters
  • ResourceArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the resource that you want to remove tags from.

    It must be the ARN of an App Runner resource.

  • TagKeys (list) --

    [REQUIRED]

    A list of tag keys that you want to remove.

    • (string) --
Return type

dict

Returns

Response Syntax

{}

Response Structure

  • (dict) --

Exceptions

update_service(**kwargs)

Update an App Runner service. You can update the source configuration and instance configuration of the service. You can also update the ARN of the auto scaling configuration resource that's associated with the service. However, you can't change the name or the encryption configuration of the service. These can be set only when you create the service.

To update the tags applied to your service, use the separate actions TagResource and UntagResource .

This is an asynchronous operation. On a successful call, you can use the returned OperationId and the ListOperations call to track the operation's progress.

See also: AWS API Documentation

Request Syntax

response = client.update_service(
    ServiceArn='string',
    SourceConfiguration={
        'CodeRepository': {
            'RepositoryUrl': 'string',
            'SourceCodeVersion': {
                'Type': 'BRANCH',
                'Value': 'string'
            },
            'CodeConfiguration': {
                'ConfigurationSource': 'REPOSITORY'|'API',
                'CodeConfigurationValues': {
                    'Runtime': 'PYTHON_3'|'NODEJS_12',
                    'BuildCommand': 'string',
                    'StartCommand': 'string',
                    'Port': 'string',
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    }
                }
            }
        },
        'ImageRepository': {
            'ImageIdentifier': 'string',
            'ImageConfiguration': {
                'RuntimeEnvironmentVariables': {
                    'string': 'string'
                },
                'StartCommand': 'string',
                'Port': 'string'
            },
            'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
        },
        'AutoDeploymentsEnabled': True|False,
        'AuthenticationConfiguration': {
            'ConnectionArn': 'string',
            'AccessRoleArn': 'string'
        }
    },
    InstanceConfiguration={
        'Cpu': 'string',
        'Memory': 'string',
        'InstanceRoleArn': 'string'
    },
    AutoScalingConfigurationArn='string',
    HealthCheckConfiguration={
        'Protocol': 'TCP'|'HTTP',
        'Path': 'string',
        'Interval': 123,
        'Timeout': 123,
        'HealthyThreshold': 123,
        'UnhealthyThreshold': 123
    }
)
Parameters
  • ServiceArn (string) --

    [REQUIRED]

    The Amazon Resource Name (ARN) of the App Runner service that you want to update.

  • SourceConfiguration (dict) --

    The source configuration to apply to the App Runner service.

    You can change the configuration of the code or image repository that the service uses. However, you can't switch from code to image or the other way around. This means that you must provide the same structure member of SourceConfiguration that you originally included when you created the service. Specifically, you can include either CodeRepository or ImageRepository . To update the source configuration, set the values to members of the structure that you include.

    • CodeRepository (dict) --

      The description of a source code repository.

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

      • RepositoryUrl (string) -- [REQUIRED]

        The location of the repository that contains the source code.

      • SourceCodeVersion (dict) -- [REQUIRED]

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

        • Type (string) -- [REQUIRED]

          The type of version identifier.

          For a git-based repository, branches represent versions.

        • Value (string) -- [REQUIRED]

          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.

      • CodeConfiguration (dict) --

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

        • ConfigurationSource (string) -- [REQUIRED]

          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.
        • CodeConfigurationValues (dict) --

          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).

          • Runtime (string) -- [REQUIRED]

            A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

          • BuildCommand (string) --

            The command App Runner runs to build your application.

          • StartCommand (string) --

            The command App Runner runs to start your application.

          • Port (string) --

            The port that your application listens to in the container.

            Default: 8080

          • RuntimeEnvironmentVariables (dict) --

            The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

            • (string) --
              • (string) --
    • ImageRepository (dict) --

      The description of a source image repository.

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

      • ImageIdentifier (string) -- [REQUIRED]

        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 .

      • ImageConfiguration (dict) --

        Configuration for running the identified image.

        • RuntimeEnvironmentVariables (dict) --

          Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

          • (string) --
            • (string) --
        • StartCommand (string) --

          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.

        • Port (string) --

          The port that your application listens to in the container.

          Default: 8080

      • ImageRepositoryType (string) -- [REQUIRED]

        The type of the image repository. This reflects the repository provider and whether the repository is private or public.

    • AutoDeploymentsEnabled (boolean) --

      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 Amazon Web Services 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).

    • AuthenticationConfiguration (dict) --

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

      • ConnectionArn (string) --

        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.

      • AccessRoleArn (string) --

        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).

  • InstanceConfiguration (dict) --

    The runtime configuration to apply to instances (scaling units) of the App Runner service.

    • Cpu (string) --

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

      Default: 1 vCPU

    • Memory (string) --

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

      Default: 2 GB

    • InstanceRoleArn (string) --

      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 Amazon Web Services APIs.

  • AutoScalingConfigurationArn (string) -- The Amazon Resource Name (ARN) of an App Runner automatic scaling configuration resource that you want to associate with your service.
  • HealthCheckConfiguration (dict) --

    The settings for the health check that App Runner performs to monitor the health of your service.

    • Protocol (string) --

      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

    • Path (string) --

      The URL that health check requests are sent to.

      Path is only applicable when you set Protocol to HTTP .

      Default: "/"

    • Interval (integer) --

      The time interval, in seconds, between health checks.

      Default: 5

    • Timeout (integer) --

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

      Default: 2

    • HealthyThreshold (integer) --

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

      Default: 1

    • UnhealthyThreshold (integer) --

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

      Default: 5

Return type

dict

Returns

Response Syntax

{
    'Service': {
        'ServiceName': 'string',
        'ServiceId': 'string',
        'ServiceArn': 'string',
        'ServiceUrl': 'string',
        'CreatedAt': datetime(2015, 1, 1),
        'UpdatedAt': datetime(2015, 1, 1),
        'DeletedAt': datetime(2015, 1, 1),
        'Status': 'CREATE_FAILED'|'RUNNING'|'DELETED'|'DELETE_FAILED'|'PAUSED'|'OPERATION_IN_PROGRESS',
        'SourceConfiguration': {
            'CodeRepository': {
                'RepositoryUrl': 'string',
                'SourceCodeVersion': {
                    'Type': 'BRANCH',
                    'Value': 'string'
                },
                'CodeConfiguration': {
                    'ConfigurationSource': 'REPOSITORY'|'API',
                    'CodeConfigurationValues': {
                        'Runtime': 'PYTHON_3'|'NODEJS_12',
                        'BuildCommand': 'string',
                        'StartCommand': 'string',
                        'Port': 'string',
                        'RuntimeEnvironmentVariables': {
                            'string': 'string'
                        }
                    }
                }
            },
            'ImageRepository': {
                'ImageIdentifier': 'string',
                'ImageConfiguration': {
                    'RuntimeEnvironmentVariables': {
                        'string': 'string'
                    },
                    'StartCommand': 'string',
                    'Port': 'string'
                },
                'ImageRepositoryType': 'ECR'|'ECR_PUBLIC'
            },
            'AutoDeploymentsEnabled': True|False,
            'AuthenticationConfiguration': {
                'ConnectionArn': 'string',
                'AccessRoleArn': 'string'
            }
        },
        'InstanceConfiguration': {
            'Cpu': 'string',
            'Memory': 'string',
            'InstanceRoleArn': 'string'
        },
        'EncryptionConfiguration': {
            'KmsKey': 'string'
        },
        'HealthCheckConfiguration': {
            'Protocol': 'TCP'|'HTTP',
            'Path': 'string',
            'Interval': 123,
            'Timeout': 123,
            'HealthyThreshold': 123,
            'UnhealthyThreshold': 123
        },
        'AutoScalingConfigurationSummary': {
            'AutoScalingConfigurationArn': 'string',
            'AutoScalingConfigurationName': 'string',
            'AutoScalingConfigurationRevision': 123
        }
    },
    'OperationId': 'string'
}

Response Structure

  • (dict) --

    • Service (dict) --

      A description of the App Runner service updated by this request. All configuration values in the returned Service structure reflect configuration changes that are being applied by this request.

      • ServiceName (string) --

        The customer-provided service name.

      • ServiceId (string) --

        An ID that App Runner generated for this service. It's unique within the Amazon Web Services Region.

      • ServiceArn (string) --

        The Amazon Resource Name (ARN) of this service.

      • ServiceUrl (string) --

        A subdomain URL that App Runner generated for this service. You can use this URL to access your service web application.

      • CreatedAt (datetime) --

        The time when the App Runner service was created. It's in the Unix time stamp format.

      • UpdatedAt (datetime) --

        The time when the App Runner service was last updated at. It's in the Unix time stamp format.

      • DeletedAt (datetime) --

        The time when the App Runner service was deleted. It's in the Unix time stamp format.

      • Status (string) --

        The current state of the App Runner service. These particular values mean the following.

        • CREATE_FAILED – The service failed to create. To troubleshoot this failure, read the failure events and logs, change any parameters that need to be fixed, and retry the call to create the service. The failed service isn't usable, and still counts towards your service quota. When you're done analyzing the failure, delete the service.
        • DELETE_FAILED – The service failed to delete and can't be successfully recovered. Retry the service deletion call to ensure that all related resources are removed.
      • SourceConfiguration (dict) --

        The source deployed to the App Runner service. It can be a code or an image repository.

        • CodeRepository (dict) --

          The description of a source code repository.

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

          • RepositoryUrl (string) --

            The location of the repository that contains the source code.

          • SourceCodeVersion (dict) --

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

            • Type (string) --

              The type of version identifier.

              For a git-based repository, branches represent versions.

            • Value (string) --

              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.

          • CodeConfiguration (dict) --

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

            • ConfigurationSource (string) --

              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.
            • CodeConfigurationValues (dict) --

              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).

              • Runtime (string) --

                A runtime environment type for building and running an App Runner service. It represents a programming language runtime.

              • BuildCommand (string) --

                The command App Runner runs to build your application.

              • StartCommand (string) --

                The command App Runner runs to start your application.

              • Port (string) --

                The port that your application listens to in the container.

                Default: 8080

              • RuntimeEnvironmentVariables (dict) --

                The environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

                • (string) --
                  • (string) --
        • ImageRepository (dict) --

          The description of a source image repository.

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

          • ImageIdentifier (string) --

            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 .

          • ImageConfiguration (dict) --

            Configuration for running the identified image.

            • RuntimeEnvironmentVariables (dict) --

              Environment variables that are available to your running App Runner service. An array of key-value pairs. Keys with a prefix of AWSAPPRUNNER are reserved for system use and aren't valid.

              • (string) --
                • (string) --
            • StartCommand (string) --

              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.

            • Port (string) --

              The port that your application listens to in the container.

              Default: 8080

          • ImageRepositoryType (string) --

            The type of the image repository. This reflects the repository provider and whether the repository is private or public.

        • AutoDeploymentsEnabled (boolean) --

          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 Amazon Web Services 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).

        • AuthenticationConfiguration (dict) --

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

          • ConnectionArn (string) --

            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.

          • AccessRoleArn (string) --

            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).

      • InstanceConfiguration (dict) --

        The runtime configuration of instances (scaling units) of this service.

        • Cpu (string) --

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

          Default: 1 vCPU

        • Memory (string) --

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

          Default: 2 GB

        • InstanceRoleArn (string) --

          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 Amazon Web Services APIs.

      • EncryptionConfiguration (dict) --

        The encryption key that App Runner uses to encrypt the service logs and the copy of the source repository that App Runner maintains for the service. It can be either a customer-provided encryption key or an Amazon Web Services managed CMK.

        • KmsKey (string) --

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

      • HealthCheckConfiguration (dict) --

        The settings for the health check that App Runner performs to monitor the health of this service.

        • Protocol (string) --

          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

        • Path (string) --

          The URL that health check requests are sent to.

          Path is only applicable when you set Protocol to HTTP .

          Default: "/"

        • Interval (integer) --

          The time interval, in seconds, between health checks.

          Default: 5

        • Timeout (integer) --

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

          Default: 2

        • HealthyThreshold (integer) --

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

          Default: 1

        • UnhealthyThreshold (integer) --

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

          Default: 5

      • AutoScalingConfigurationSummary (dict) --

        Summary information for the App Runner automatic scaling configuration resource that's associated with this service.

        • AutoScalingConfigurationArn (string) --

          The Amazon Resource Name (ARN) of this auto scaling configuration.

        • AutoScalingConfigurationName (string) --

          The customer-provided auto scaling configuration name. It can be used in multiple revisions of a configuration.

        • AutoScalingConfigurationRevision (integer) --

          The revision of this auto scaling configuration. It's unique among all the active configurations ("Status": "ACTIVE" ) with the same AutoScalingConfigurationName .

    • OperationId (string) --

      The unique ID of the asynchronous operation that this request started. You can use it combined with the ListOperations call to track the operation's progress.

Exceptions

Client Exceptions

Client exceptions are available on a client instance via the exceptions property. For more detailed instructions and examples on the exact usage of client exceptions, see the error handling user guide.

The available client exceptions are:

class AppRunner.Client.exceptions.InternalServiceErrorException

An unexpected service exception occurred.

Example

try:
  ...
except client.exceptions.InternalServiceErrorException as e:
  print(e.response)
response

The parsed error response. All exceptions have a top level Error key that provides normalized access to common exception atrributes. All other keys are specific to this service or exception class.

Syntax

{
    'Message': 'string',
    'Error': {
        'Code': 'string',
        'Message': 'string'
    }
}

Structure

  • (dict) --

    An unexpected service exception occurred.

    • Message (string) --
    • Error (dict) -- Normalized access to common exception attributes.
      • Code (string) -- An identifier specifying the exception type.
      • Message (string) -- A descriptive message explaining why the exception occured.
class AppRunner.Client.exceptions.InvalidRequestException

One or more input parameters aren't valid. Refer to the API action's document page, correct the input parameters, and try the action again.

Example

try:
  ...
except client.exceptions.InvalidRequestException as e:
  print(e.response)
response

The parsed error response. All exceptions have a top level Error key that provides normalized access to common exception atrributes. All other keys are specific to this service or exception class.

Syntax

{
    'Message': 'string',
    'Error': {
        'Code': 'string',
        'Message': 'string'
    }
}

Structure

  • (dict) --

    One or more input parameters aren't valid. Refer to the API action's document page, correct the input parameters, and try the action again.

    • Message (string) --
    • Error (dict) -- Normalized access to common exception attributes.
      • Code (string) -- An identifier specifying the exception type.
      • Message (string) -- A descriptive message explaining why the exception occured.
class AppRunner.Client.exceptions.InvalidStateException

You can't perform this action when the resource is in its current state.

Example

try:
  ...
except client.exceptions.InvalidStateException as e:
  print(e.response)
response

The parsed error response. All exceptions have a top level Error key that provides normalized access to common exception atrributes. All other keys are specific to this service or exception class.

Syntax

{
    'Message': 'string',
    'Error': {
        'Code': 'string',
        'Message': 'string'
    }
}

Structure

  • (dict) --

    You can't perform this action when the resource is in its current state.

    • Message (string) --
    • Error (dict) -- Normalized access to common exception attributes.
      • Code (string) -- An identifier specifying the exception type.
      • Message (string) -- A descriptive message explaining why the exception occured.
class AppRunner.Client.exceptions.ResourceNotFoundException

A resource doesn't exist for the specified Amazon Resource Name (ARN) in your Amazon Web Services account.

Example

try:
  ...
except client.exceptions.ResourceNotFoundException as e:
  print(e.response)
response

The parsed error response. All exceptions have a top level Error key that provides normalized access to common exception atrributes. All other keys are specific to this service or exception class.

Syntax

{
    'Message': 'string',
    'Error': {
        'Code': 'string',
        'Message': 'string'
    }
}

Structure

  • (dict) --

    A resource doesn't exist for the specified Amazon Resource Name (ARN) in your Amazon Web Services account.

    • Message (string) --
    • Error (dict) -- Normalized access to common exception attributes.
      • Code (string) -- An identifier specifying the exception type.
      • Message (string) -- A descriptive message explaining why the exception occured.
class AppRunner.Client.exceptions.ServiceQuotaExceededException

App Runner can't create this resource. You've reached your account quota for this resource type.

For App Runner per-resource quotas, see App Runner endpoints and quotas in the Amazon Web Services General Reference .

Example

try:
  ...
except client.exceptions.ServiceQuotaExceededException as e:
  print(e.response)
response

The parsed error response. All exceptions have a top level Error key that provides normalized access to common exception atrributes. All other keys are specific to this service or exception class.

Syntax

{
    'Message': 'string',
    'Error': {
        'Code': 'string',
        'Message': 'string'
    }
}

Structure

  • (dict) --

    App Runner can't create this resource. You've reached your account quota for this resource type.

    For App Runner per-resource quotas, see App Runner endpoints and quotas in the Amazon Web Services General Reference .

    • Message (string) --
    • Error (dict) -- Normalized access to common exception attributes.
      • Code (string) -- An identifier specifying the exception type.
      • Message (string) -- A descriptive message explaining why the exception occured.

Paginators

The available paginators are: