aws-cdk-lib.aws_servicecatalog.CloudFormationTemplate

class CloudFormationTemplate

LanguageType name
.NETAmazon.CDK.AWS.Servicecatalog.CloudFormationTemplate
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awsservicecatalog#CloudFormationTemplate
Javasoftware.amazon.awscdk.services.servicecatalog.CloudFormationTemplate
Pythonaws_cdk.aws_servicecatalog.CloudFormationTemplate
TypeScript (source)aws-cdk-lib » aws_servicecatalog » CloudFormationTemplate

Represents the Product Provisioning Artifact Template.

Example

import * as cdk from 'aws-cdk-lib';

class S3BucketProduct extends servicecatalog.ProductStack {
  constructor(scope: Construct, id: string) {
    super(scope, id);

    new s3.Bucket(this, 'BucketProduct');
  }
}

const product = new servicecatalog.CloudFormationProduct(this, 'Product', {
  productName: "My Product",
  owner: "Product Owner",
  productVersions: [
    {
      productVersionName: "v1",
      cloudFormationTemplate: servicecatalog.CloudFormationTemplate.fromProductStack(new S3BucketProduct(this, 'S3BucketProduct')),
    },
  ],
});

Initializer

new CloudFormationTemplate()

Methods

NameDescription
bind(scope)Called when the product is initialized to allow this object to bind to the stack, add resources and have fun.
static fromAsset(path, options?)Loads the provisioning artifacts template from a local disk path.
static fromProductStack(productStack)Creates a product with the resources defined in the given product stack.
static fromUrl(url)Template from URL.

bind(scope)

public bind(scope: Construct): CloudFormationTemplateConfig

Parameters

  • scope Construct — The binding scope.

Returns

  • CloudFormationTemplateConfig

Called when the product is initialized to allow this object to bind to the stack, add resources and have fun.


static fromAsset(path, options?)

public static fromAsset(path: string, options?: AssetOptions): CloudFormationTemplate

Parameters

  • path string — A file containing the provisioning artifacts.
  • options AssetOptions

Returns

  • CloudFormationTemplate

Loads the provisioning artifacts template from a local disk path.


static fromProductStack(productStack)

public static fromProductStack(productStack: ProductStack): CloudFormationTemplate

Parameters

  • productStack ProductStack

Returns

  • CloudFormationTemplate

Creates a product with the resources defined in the given product stack.


static fromUrl(url)

public static fromUrl(url: string): CloudFormationTemplate

Parameters

  • url string — The url that points to the provisioning artifacts template.

Returns

  • CloudFormationTemplate

Template from URL.