initial commit of replacement infrastructure automation
[awsible] / infrastructure / modules / terraform-infrastructure / main.tf
diff --git a/infrastructure/modules/terraform-infrastructure/main.tf b/infrastructure/modules/terraform-infrastructure/main.tf
new file mode 100644 (file)
index 0000000..1da303d
--- /dev/null
@@ -0,0 +1,19 @@
+resource "aws_s3_bucket" "tf_state" {
+       bucket = "${var.remote_state_bucket}"
+       region = "${var.region}"
+       acl = "private"
+       versioning {
+               enabled = true
+       }
+}
+
+resource "aws_dynamodb_table" "tf_lock" {
+       name = "${var.remote_state_table}"
+       read_capacity = 1
+       write_capacity = 1
+       hash_key = "LockID"
+       attribute {
+               name = "LockID"
+               type = "S"
+       }
+}