Skip to content

Commit 77fa12c

Browse files
authored
feat!: Update for TF and CI, add instance test (#59)
feat: Update TPG for tenant_project, add test * Update minimum TF to 0.13, TPG to 4.12, and TF modultes * Update to CFT 1.5 * Convert template simple_example test to new instance test * Update tenant_project output method * Update instance example functionality
1 parent 160511b commit 77fa12c

File tree

36 files changed

+152
-169
lines changed

36 files changed

+152
-169
lines changed

.github/workflows/stale.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,17 @@
1+
# Copyright 2022 Google LLC
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
115
name: "Close stale issues"
216
on:
317
schedule:

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
# Make will use bash instead of sh
1919
SHELL := /usr/bin/env bash
2020

21-
DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 1.0
21+
DOCKER_TAG_VERSION_DEVELOPER_TOOLS := 1.5
2222
DOCKER_IMAGE_DEVELOPER_TOOLS := cft/developer-tools
2323
REGISTRY_URL := gcr.io/cloud-foundation-cicd
2424

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ These sections describe requirements for using this module.
5454

5555
The following dependencies must be available:
5656

57-
- [Terraform][terraform] v0.12
58-
- [Terraform Provider for GCP][terraform-provider-gcp] plugin v2.0
57+
- [Terraform][terraform] v0.13+
58+
- [Terraform Provider for GCP][terraform-provider-gcp] plugin v4.12
5959

6060
### Service Account
6161

build/int.cloudbuild.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,4 @@ tags:
3838
- 'integration'
3939
substitutions:
4040
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
41-
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.0'
41+
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.5'

build/lint.cloudbuild.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,4 @@ tags:
2121
- 'lint'
2222
substitutions:
2323
_DOCKER_IMAGE_DEVELOPER_TOOLS: 'cft/developer-tools'
24-
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.0'
24+
_DOCKER_TAG_VERSION_DEVELOPER_TOOLS: '1.5'

examples/hub_artifact/versions.tf

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
/**
2+
* Copyright 2022 Google LLC
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
117
terraform {
218
required_providers {
319
cdap = {

examples/instance/README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,14 @@ This example illustrates how to use the `data-fusion` module.
77

88
| Name | Description | Type | Default | Required |
99
|------|-------------|------|---------|:--------:|
10+
| data\_fusion\_service\_account | Google Managed Data Fusion Service Account Email | `any` | n/a | yes |
1011
| project\_id | The ID of the project in which to provision resources. | `string` | n/a | yes |
1112

1213
## Outputs
1314

14-
No output.
15+
| Name | Description |
16+
|------|-------------|
17+
| instance\_id | The created Google Data Fusion instance ID |
1518

1619
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->
1720

examples/instance/main.tf

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@
1717
module "data_fusion" {
1818
source = "../../"
1919

20-
name = "example-instance"
21-
project = var.project_id
22-
region = "us-central1"
20+
name = "example-instance"
21+
project = var.project_id
22+
region = "us-central1"
23+
network = "default"
24+
data_fusion_service_account = var.data_fusion_service_account
2325
}

examples/instance/simple/versions.tf renamed to examples/instance/outputs.tf

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* Copyright 2020 Google LLC
2+
* Copyright 2022 Google LLC
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -14,6 +14,7 @@
1414
* limitations under the License.
1515
*/
1616

17-
terraform {
18-
required_version = ">= 0.12"
17+
output "instance_id" {
18+
description = "The created Google Data Fusion instance ID"
19+
value = module.data_fusion.instance.id
1920
}

examples/instance/simple/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ This example illustrates how to use the `data-fusion` module.
77

88
| Name | Description | Type | Default | Required |
99
|------|-------------|------|---------|:--------:|
10+
| data\_fusion\_service\_account | Google Managed Data Fusion Service Account Email | `any` | n/a | yes |
1011
| project\_id | The ID of the project in which to provision resources. | `string` | n/a | yes |
1112

1213
## Outputs

0 commit comments

Comments
 (0)