File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -299,6 +299,27 @@ resource "oci_core_network_security_group_security_rule" "workers_healthcheck_in
299
299
}
300
300
}
301
301
302
+ resource "oci_core_network_security_group_security_rule" "workers_ssh_ingress_from_bastion" {
303
+ network_security_group_id = oci_core_network_security_group. workers . id
304
+ description = " Allow ssh access to workers via Bastion host"
305
+ direction = " INGRESS"
306
+ protocol = local. tcp_protocol
307
+ source = local. bastion_subnet
308
+ source_type = " CIDR_BLOCK"
309
+
310
+ stateless = false
311
+
312
+ tcp_options {
313
+ destination_port_range {
314
+ min = local. ssh_port
315
+ max = local. ssh_port
316
+ }
317
+ }
318
+
319
+ count = var. allow_worker_ssh_access == true ? 1 : 0
320
+
321
+ }
322
+
302
323
# internal lb nsg and rules
303
324
resource "oci_core_network_security_group" "int_lb" {
304
325
compartment_id = var. compartment_id
You can’t perform that action at this time.
0 commit comments