AWS Backup Vault

This page shows how to write Terraform and CloudFormation for AWS Backup Vault and write them securely.

aws_backup_vault (Terraform)

The Vault in AWS Backup can be configured in Terraform with the resource name aws_backup_vault. The following sections describe 4 examples of how to use the resource and its parameters.

Example Usage from GitHub

github-iconUSSBA/terraform-aws-backup-plans
resource "aws_backup_vault" "daily" {
  count = local.daily_backup_count
  name  = "daily"
  tags  = merge(var.tags, var.tags_vault)
}
resource "aws_backup_vault" "daily_cross_region" {
github-icondevopsbynaresh/alsac-raja-automation-jenkins
resource "aws_backup_vault" "jenkins_vault" {
  provider    = aws.use1
  name        = "jenkins_vault"
  kms_key_arn = "arn:aws:kms:us-east-1:143269240300:key/cb211a28-db0b-4355-83f6-b824067811d5"
}

github-icongilyas/infracost
resource "aws_backup_vault" "usage" {
  name = "aws_backup_vault"
}

resource "aws_backup_vault" "non_usage" {
  name = "aws_backup_vault"
github-iconinfracost/infracost
resource "aws_backup_vault" "usage" {
  name = "aws_backup_vault"
}

resource "aws_backup_vault" "non_usage" {
  name = "aws_backup_vault"

Parameters

Explanation in Terraform Registry

Provides an AWS Backup vault resource.

AWS::Backup::BackupVault (CloudFormation)

The BackupVault in Backup can be configured in CloudFormation with the resource name AWS::Backup::BackupVault. The following sections describe how to use the resource and its parameters.

Parameters

Explanation in CloudFormation Registry

Creates a logical container where backups are stored. A CreateBackupVault request includes a name, optionally one or more resource tags, an encryption key, and a request ID.

Note Do not include sensitive data, such as passport numbers, in the name of a backup vault.

Frequently asked questions

What is AWS Backup Vault?

AWS Backup Vault is a resource for Backup of Amazon Web Service. Settings can be wrote in Terraform and CloudFormation.

Where can I find the example code for the AWS Backup Vault?

For Terraform, the USSBA/terraform-aws-backup-plans, devopsbynaresh/alsac-raja-automation-jenkins and gilyas/infracost source code examples are useful. See the Terraform Example section for further details.