AWS Fundamentals Logo
AWS Fundamentals
L1 ConstructAWS::MemoryDB::SubnetGroup

CfnSubnetGroup

Specifies a subnet group. A subnet group is a collection of subnets (typically private) that you can designate for your cluster s running in an Amazon Virtual Private Cloud (VPC) environment. When you create a cluster in an Amazon VPC , you must specify a subnet group. MemoryDB uses that subnet group to choose a subnet and IP addresses within that subnet to associate with your nodes. For more information, see [Subnets and subnet groups](https://docs.aws.amazon.com/memorydb/latest/devguide/subnetgroups.html) .

Import

import { CfnSubnetGroup } from 'aws-cdk-lib/aws-memorydb';

Or use the module namespace:

import * as memorydb from 'aws-cdk-lib/aws-memorydb';
// memorydb.CfnSubnetGroup

Properties

Configuration passed to the constructor as CfnSubnetGroupProps.

subnetGroupNameRequired
string

The name of the subnet group to be used for the cluster .

subnetIdsRequired
string | ISubnetRef[]

A list of Amazon VPC subnet IDs for the subnet group.

descriptionOptional
string

A description of the subnet group.

tagsOptional
CfnTag[]

An array of key-value pairs to apply to this resource. For more information, see [Tag](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-resource-tags.html) .

CloudFormation Resource

This L1 construct maps directly to the following CloudFormation resource type.

Learn AWS the Practical Way

Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.

Subscribe to Newsletter

Quick Facts

LevelL1 (CloudFormation)
Moduleaws-memorydb
CFN TypeAWS::MemoryDB::SubnetGroup
Properties4

External Links