Skip to content

Commit 9198209

Browse files
committed
Test both load_balancing_scheme and backend_service set
1 parent 37b654b commit 9198209

2 files changed

Lines changed: 32 additions & 0 deletions

File tree

mmv1/products/compute/TargetTcpProxy.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,13 @@ examples:
4747
target_tcp_proxy_name: 'test-proxy'
4848
backend_service_name: 'backend-service'
4949
health_check_name: 'health-check'
50+
- name: 'target_tcp_proxy_basic_beta'
51+
min_version: beta
52+
primary_resource_id: 'default'
53+
vars:
54+
target_tcp_proxy_name: 'test-proxy'
55+
backend_service_name: 'backend-service'
56+
health_check_name: 'health-check'
5057
- name: target_tcp_proxy_backendless
5158
min_version: beta
5259
primary_resource_id: default
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
resource "google_compute_target_tcp_proxy" "{{$.PrimaryResourceId}}" {
2+
provider = google-beta
3+
name = "{{index $.Vars "target_tcp_proxy_name"}}"
4+
load_balancing_scheme = "EXTERNAL_MANAGED"
5+
backend_service = google_compute_backend_service.default.id
6+
}
7+
8+
resource "google_compute_backend_service" "default" {
9+
name = "{{index $.Vars "backend_service_name"}}"
10+
load_balancing_scheme = "EXTERNAL_MANAGED"
11+
protocol = "TCP"
12+
timeout_sec = 10
13+
14+
health_checks = [google_compute_health_check.default.id]
15+
}
16+
17+
resource "google_compute_health_check" "default" {
18+
name = "{{index $.Vars "health_check_name"}}"
19+
timeout_sec = 1
20+
check_interval_sec = 1
21+
22+
tcp_health_check {
23+
port = "443"
24+
}
25+
}

0 commit comments

Comments
 (0)