ElastiCache redis cluster with secure firewall configuration, encryption, multi AZ, backup enabled, and alerting

Usage no npm install needed!

<script type="module">
  import cfnModulesElasticacheRedis from 'https://cdn.skypack.dev/@cfn-modules/elasticache-redis';


Build Status NPM version

cfn-modules: ElastiCache redis

ElastiCache redis cluster with secure firewall configuration, encryption, multi AZ, backup enabled, and alerting.


Install Node.js and npm first!

npm i @cfn-modules/elasticache-redis


AWSTemplateFormatVersion: '2010-09-09'
Description: 'cfn-modules example'
    Type: 'AWS::CloudFormation::Stack'
        VpcModule: !GetAtt 'Vpc.Outputs.StackName' # required
        ClientSgModule: !GetAtt 'ClientSg.Outputs.StackName' # required
        AlertingModule: '' # optional
        BastionModule: '' # optional
        KmsKeyModule: '' # optional
        EngineVersion: '5.0.5' # optional
        CacheNodeType: 'cache.t2.micro' # optional
        TransitEncryption: 'true' # optional
        AuthToken: '' # optional
        SnapshotRetentionLimit: '35' # optional
        SnapshotName: '' # optional
        NumShards: '1' # optional
        NumReplicas: '1' # optional
      TemplateURL: './node_modules/@cfn-modules/elasticache-redis/module.yml'



Related modules



Name Description Default Required? Allowed values
VpcModule Stack name of vpc module yes
ClientSgModule Stack name of client-sg module where traffic is allowed from on port 6379 to the cache yes
AlertingModule Stack name of alerting module no
BastionModule Stack name of module implementing Bastion no
KmsKeyModule Stack name of kms-key module no
EngineVersion Redis version 5.0.5 no [5.0.5]
CacheNodeType TThe compute and memory capacity of the nodes in the node group (shard) cache.t2.micro no
TransitEncryption Enable [encryption for data in transit](https://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/in-transit-encryption.html)? true no [true, false]
AuthToken Password (16 to 128 characters) used to authenticate against Redis (requires TransitEncryption := true; leave blank to disable password-protection) no
SnapshotRetentionLimit The number of days for which ElastiCache retains automatic snapshots before deleting them (set to 0 to disable backups) 35 no [0...35]
SnapshotName Name of a snapshot from which you want to restore (leave blank to create an empty cache) no
NumShards Number of shards in the cluster. 1 no [1-250]
NumReplicas Number of replicas per shard. 1 no [0-5]


  • Scalable: Cache instances capacity (CPU, RAM, network, ...) is limited by design
  • Monitoring: Network In+Out is not monitored according to capacity of instance type