forked from veriskope/terraform-adobe-media-server
-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.tf
40 lines (37 loc) · 1015 Bytes
/
main.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# Configure the AWS Providers
provider "aws" {
version = "~> 2.0"
region = "us-west-2"
alias = "usw2"
}
provider "aws" {
version = "~> 2.0"
region = "eu-west-2"
alias = "euw2"
}
# Bucket initially created using AWS CLI
#
# aws s3api create-bucket --bucket ams-terraform-backend-store \
# --region us-west-2 \
# --create-bucket-configuration \
# LocationConstraint=us-west-2
#
# aws s3api put-bucket-encryption \
# --bucket ams-terraform-backend-store \
# --public-access-block-configuration '{
# "BlockPublicAcls": true,
# "IgnorePublicAcls": true,
# "BlockPublicPolicy": true,
# "RestrictPublicBuckets": true
# }'
# --server-side-encryption-configuration={\"Rules\":[{\"ApplyServerSideEncryptionByDefault\":{\"SSEAlgorithm\":\"AES256\"}}]}
#
data "terraform_remote_state" "s3" {
backend = "s3"
config = {
bucket = "ams-terraform-backend-store"
encrypt = true
key = "terraform/terraform.tfstate"
region = "us-west-2"
}
}