-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add ability to specifiy vault policy. * Update the docs. * Add ability to specify KMS key.
- Loading branch information
1 parent
378f55a
commit 48e405b
Showing
3 changed files
with
26 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,12 @@ | ||
resource "aws_backup_vault" "this" { | ||
name = var.name | ||
tags = var.tags | ||
name = var.name | ||
tags = var.tags | ||
kms_key_arn = try(var.backup_vault_kms_key_arn, null) | ||
} | ||
|
||
# Created if the policy JSON is supplied. | ||
resource "aws_backup_vault_policy" "this" { | ||
count = var.backup_vault_policy_json != "" ? 1 : 0 | ||
backup_vault_name = aws_backup_vault.this.name | ||
policy = var.backup_vault_policy_json | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters