File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change 1
- data "oci_containerengine_node_pool " "oke_node_pool " {
2
- node_pool_id = var. node_pool_id
1
+ data "oci_core_instances " "instances " {
2
+ compartment_id = var. compartment_id
3
3
}
4
4
5
5
resource "oci_network_load_balancer_network_load_balancer" "nlb" {
@@ -40,17 +40,17 @@ resource "oci_network_load_balancer_backend" "nlb_backend_http" {
40
40
network_load_balancer_id = oci_network_load_balancer_network_load_balancer. nlb . id
41
41
port = var. node_port_http
42
42
depends_on = [oci_network_load_balancer_backend_set . nlb_backend_set_http ]
43
- count = length (data . oci_containerengine_node_pool . oke_node_pool . nodes )
44
- target_id = data. oci_containerengine_node_pool . oke_node_pool . nodes [count . index ]. id
43
+ count = var . node_size
44
+ target_id = data. oci_core_instances . instances . instances [count . index ]. id
45
45
}
46
46
47
47
resource "oci_network_load_balancer_backend" "nlb_backend_https" {
48
48
backend_set_name = oci_network_load_balancer_backend_set. nlb_backend_set_https . name
49
49
network_load_balancer_id = oci_network_load_balancer_network_load_balancer. nlb . id
50
50
port = var. node_port_https
51
51
depends_on = [oci_network_load_balancer_backend_set . nlb_backend_set_https ]
52
- count = length (data . oci_containerengine_node_pool . oke_node_pool . nodes )
53
- target_id = data. oci_containerengine_node_pool . oke_node_pool . nodes [count . index ]. id
52
+ count = var . node_size
53
+ target_id = data. oci_core_instances . instances . instances [count . index ]. id
54
54
}
55
55
56
56
resource "oci_network_load_balancer_listener" "nlb_listener_http" {
You can’t perform that action at this time.
0 commit comments