Skip to content

Commit d878d2d

Browse files
zxjinnbrandonjbjelland
authored andcommitted
Create bucket before provisioning access logs on the ALB
* Create bucket before provisioning access logs on the ALB * gemfile fixed to pull from rubygems
1 parent 170a68b commit d878d2d

File tree

3 files changed

+4
-7
lines changed

3 files changed

+4
-7
lines changed

Gemfile

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,5 @@ source 'https://rubygems.org/' do
44
gem 'kitchen-verifier-awspec'
55
gem 'rhcl'
66
gem 'awspec'
7+
gem 'kitchen-terraform', '>= 3.0.0'
78
end
8-
9-
gem(
10-
"kitchen-terraform",
11-
git: "https://github.com/newcontext-oss/kitchen-terraform",
12-
branch: "ncs-alane-3.0.0"
13-
)

main.tf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ resource "aws_alb" "main" {
1717
prefix = "${var.log_location_prefix}"
1818
enabled = "${var.enable_logging}"
1919
}
20+
21+
depends_on = ["aws_s3_bucket.log_bucket"]
2022
}
2123

2224
data "aws_iam_policy_document" "bucket_policy" {

variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ variable "enable_logging" {
9696
}
9797

9898
variable "log_bucket_name" {
99-
description = "S3 bucket for storing ALB access logs. Setting this means the module will try to create the bucket."
99+
description = "S3 bucket for storing ALB access logs. To create the bucket \"create_log_bucket\" should be set to true."
100100
default = ""
101101
}
102102

0 commit comments

Comments
 (0)