Skip to content

Commit a153472

Browse files
author
Aaron Lane
authored
Merge pull request #23 from terraform-google-modules/bugfix/output-map
Fix bug in outputs when removing buckets
2 parents 2d968b5 + 09f8be9 commit a153472

File tree

6 files changed

+21
-11
lines changed

6 files changed

+21
-11
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
# Make will use bash instead of sh
1616
SHELL := /usr/bin/env bash
1717

18-
DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 0.1.0
18+
DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 0.6.0
1919
DOCKER_IMAGE_DEVELOPER_TOOLS := cft/developer-tools
2020
REGISTRY_URL := gcr.io/cloud-foundation-cicd
2121

build/int.cloudbuild.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ steps:
2121
- 'TF_VAR_org_id=$_ORG_ID'
2222
- 'TF_VAR_folder_id=$_FOLDER_ID'
2323
- 'TF_VAR_billing_account=$_BILLING_ACCOUNT'
24+
- id: sleep
25+
name: 'gcr.io/cloud-foundation-cicd/$_DOCKER_IMAGE_DEVELOPER_TOOLS:$_DOCKER_TAG_VERSION_DEVELOPER_TOOLS'
26+
args: ['/bin/bash', '-c', 'sleep 120']
2427
- id: create
2528
name: 'gcr.io/cloud-foundation-cicd/$_DOCKER_IMAGE_DEVELOPER_TOOLS:$_DOCKER_TAG_VERSION_DEVELOPER_TOOLS'
2629
args: ['/bin/bash', '-c', 'source /usr/local/bin/task_helper_functions.sh && kitchen_do create']
@@ -38,4 +41,4 @@ tags:
3841
- 'integration'
3942
substitutions:
4043
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
41-
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '0.1.0'
44+
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '0.6.0'

build/lint.cloudbuild.yaml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2018 Google LLC
1+
# Copyright 2019 Google LLC
22
#
33
# Licensed under the Apache License, Version 2.0 (the "License");
44
# you may not use this file except in compliance with the License.
@@ -13,9 +13,12 @@
1313
# limitations under the License.
1414

1515
steps:
16-
- name: "gcr.io/cloud-foundation-cicd/cft/developer-tools:0.0.1"
17-
id: "lint"
18-
args: ["/usr/local/bin/test_lint.sh"]
16+
- id: 'lint-tests'
17+
name: 'gcr.io/cloud-foundation-cicd/$_DOCKER_IMAGE_DEVELOPER_TOOLS:$_DOCKER_TAG_VERSION_DEVELOPER_TOOLS'
18+
args: ['/usr/local/bin/test_lint.sh']
1919
tags:
20-
- "ci"
21-
- "lint"
20+
- 'ci'
21+
- 'lint'
22+
substitutions:
23+
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
24+
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '0.6.0'

examples/simple_example/main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
*/
1616

1717
provider "google" {
18-
version = "~> 2.0"
18+
version = "~> 2.18.0"
1919
}
2020

2121
module "cloud_storage" {

outputs.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,12 @@ output "buckets" {
3636

3737
output "names" {
3838
description = "Bucket names."
39-
value = zipmap(var.names, google_storage_bucket.buckets[*].name)
39+
value = zipmap(var.names, slice(google_storage_bucket.buckets[*].name, 0, length(var.names)))
4040
}
4141

4242
output "urls" {
4343
description = "Bucket URLs."
44-
value = zipmap(var.names, google_storage_bucket.buckets[*].url)
44+
value = zipmap(var.names, slice(google_storage_bucket.buckets[*].url, 0, length(var.names)))
4545
}
4646

4747
output "names_list" {

test/setup/versions.tf

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@
1414
* limitations under the License.
1515
*/
1616

17+
provider "google" {
18+
version = "~> 2.18.0"
19+
}
20+
1721
terraform {
1822
required_version = ">= 0.12"
1923
}

0 commit comments

Comments
 (0)