nozaq / terraform-aws-secure-baseline

Terraform module to set up your AWS account with the secure baseline configuration based on CIS Amazon Web Services Foundations and AWS Foundational Security Best Practices.
MIT License
1.14k stars 372 forks source link

Not liking trim function in bucket.tf #159

Closed quintinwhite closed 3 years ago

quintinwhite commented 3 years ago

Error: Call to unknown function

on bucket.tf line 10, in locals: 10: audit_log_cloudtrail_destination = join("/", [local.audit_log_bucket_arn, trim(var.cloudtrail_s3_key_prefix, "/")])

There is no function named "trim".

Error: Call to unknown function

on bucket.tf line 11, in locals: 11: audit_log_config_destination = join("/", [local.audit_log_bucket_arn, trim(var.config_s3_bucket_key_prefix, "/")])

There is no function named "trim".

Error: Call to unknown function

on bucket.tf line 12, in locals: 12: audit_log_flow_logs_destination = join("/", [local.audit_log_bucket_arn, trim(var.vpc_flow_logs_s3_key_prefix, "/")])

There is no function named "trim".

quintinwhite commented 3 years ago

seems like the trim function is not available in all versions of terraform, upgraded to v14.