<% buckets.each do |bucket| -%> resource "aws_s3_bucket" "<%= module_name_of(bucket) %>" { bucket = "<%= bucket.name %>" acl = "private" <%- unless (policy = bucket_policy_of(bucket)).nil? -%> policy = < POLICY <%- end -%> } <% end -%>