aws-cdk-lib.aws_lightsail.CfnContainerProps

interface CfnContainerProps

LanguageType name
.NETAmazon.CDK.AWS.Lightsail.CfnContainerProps
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awslightsail#CfnContainerProps
Javasoftware.amazon.awscdk.services.lightsail.CfnContainerProps
Pythonaws_cdk.aws_lightsail.CfnContainerProps
TypeScript aws-cdk-lib » aws_lightsail » CfnContainerProps

Properties for defining a CfnContainer.

Example

// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_lightsail as lightsail } from 'aws-cdk-lib';
const cfnContainerProps: lightsail.CfnContainerProps = {
  power: 'power',
  scale: 123,
  serviceName: 'serviceName',

  // the properties below are optional
  containerServiceDeployment: {
    containers: [{
      command: ['command'],
      containerName: 'containerName',
      environment: [{
        value: 'value',
        variable: 'variable',
      }],
      image: 'image',
      ports: [{
        port: 'port',
        protocol: 'protocol',
      }],
    }],
    publicEndpoint: {
      containerName: 'containerName',
      containerPort: 123,
      healthCheckConfig: {
        healthyThreshold: 123,
        intervalSeconds: 123,
        path: 'path',
        successCodes: 'successCodes',
        timeoutSeconds: 123,
        unhealthyThreshold: 123,
      },
    },
  },
  isDisabled: false,
  publicDomainNames: [{
    certificateName: 'certificateName',
    domainNames: ['domainNames'],
  }],
  tags: [{
    key: 'key',
    value: 'value',
  }],
};

Properties

NameTypeDescription
powerstringThe power specification of the container service.
scalenumberThe scale specification of the container service.
serviceNamestringThe name of the container service.
containerServiceDeployment?IResolvable | ContainerServiceDeploymentPropertyAn object that describes the current container deployment of the container service.
isDisabled?boolean | IResolvableA Boolean value indicating whether the container service is disabled.
publicDomainNames?IResolvable | IResolvable | PublicDomainNameProperty[]The public domain name of the container service, such as example.com and www.example.com .
tags?CfnTag[]An array of key-value pairs to apply to this resource.

power

Type: string

The power specification of the container service.

The power specifies the amount of RAM, the number of vCPUs, and the base price of the container service.


scale

Type: number

The scale specification of the container service.

The scale specifies the allocated compute nodes of the container service.


serviceName

Type: string

The name of the container service.


containerServiceDeployment?

Type: IResolvable | ContainerServiceDeploymentProperty (optional)

An object that describes the current container deployment of the container service.


isDisabled?

Type: boolean | IResolvable (optional)

A Boolean value indicating whether the container service is disabled.


publicDomainNames?

Type: IResolvable | IResolvable | PublicDomainNameProperty[] (optional)

The public domain name of the container service, such as example.com and www.example.com .

You can specify up to four public domain names for a container service. The domain names that you specify are used when you create a deployment with a container that is configured as the public endpoint of your container service.

If you don't specify public domain names, then you can use the default domain of the container service.

You must create and validate an SSL/TLS certificate before you can use public domain names with your container service. Use the AWS::Lightsail::Certificate resource to create a certificate for the public domain names that you want to use with your container service.


tags?

Type: CfnTag[] (optional)

An array of key-value pairs to apply to this resource.

For more information, see Tag in the AWS CloudFormation User Guide .

The Value of Tags is optional for Lightsail resources.