Skip to content

Commit

Permalink
Merge pull request #2 from dxw/0.12-fixes
Browse files Browse the repository at this point in the history
Fixes for terraform 0.12
  • Loading branch information
rjw1 authored Dec 31, 2019
2 parents 0b5f5ba + 114d53e commit 5c663d8
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ data "aws_region" "_" {}
data "template_file" "codebuild_source_location" {
template = "https://github.com/$${owner}/$${repository}.git"

vars {
vars = {
owner = "${var.github_owner}"
repository = "${var.github_repository}"
}
Expand All @@ -47,7 +47,7 @@ data "template_file" "codebuild_source_location" {
data "template_file" "codebuild_iam_policy" {
template = "${file("${path.module}/iam/policies/codebuild.json")}"

vars {
vars = {
bucket = "${aws_s3_bucket._.bucket}"
}
}
Expand Down Expand Up @@ -120,7 +120,13 @@ resource "aws_codebuild_project" "_" {
type = "LINUX_CONTAINER"
image = "${var.codebuild_image}"
privileged_mode = "${var.codebuild_privileged_mode}"
environment_variable = "${var.codebuild_environment_variables}"
dynamic "environment_variable" {
for_each = var.codebuild_environment_variables
content {
name = environment_variable.value.name
value = environment_variable.value.value
}
}
}

artifacts {
Expand Down

0 comments on commit 5c663d8

Please sign in to comment.