Skip to content

Commit a388923

Browse files
authored
Merge pull request #2127 from oracle-devrel/oke-rm
oke-rm-1.1.6
2 parents f0d8be5 + 75e0a1b commit a388923

File tree

9 files changed

+902
-69
lines changed

9 files changed

+902
-69
lines changed

app-dev/devops-and-containers/oke/oke-rm/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ This stack is used to create the initial network infrastructure for OKE. When co
1616
* By default, everything is private, but there is the possibility to create public subnets
1717
* Be careful when modifying the default values, as inputs are not validated
1818

19-
[![Deploy to Oracle Cloud](https://oci-resourcemanager-plugin.plugins.oci.oraclecloud.com/latest/deploy-to-oracle-cloud.svg)](https://cloud.oracle.com/resourcemanager/stacks/create?zipUrl=https://github.com/oracle-devrel/technology-engineering/releases/download/oke-rm-1.1.5/infra.zip)
19+
[![Deploy to Oracle Cloud](https://oci-resourcemanager-plugin.plugins.oci.oraclecloud.com/latest/deploy-to-oracle-cloud.svg)](https://cloud.oracle.com/resourcemanager/stacks/create?zipUrl=https://github.com/oracle-devrel/technology-engineering/releases/download/oke-rm-1.1.6/infra.zip)
2020

2121
## Step 2: Create the OKE control plane
2222

2323
This stack is used to create the OKE control plane ONLY.
2424

25-
[![Deploy to Oracle Cloud](https://oci-resourcemanager-plugin.plugins.oci.oraclecloud.com/latest/deploy-to-oracle-cloud.svg)](https://cloud.oracle.com/resourcemanager/stacks/create?zipUrl=https://github.com/oracle-devrel/technology-engineering/releases/download/oke-rm-1.1.5/oke.zip)
25+
[![Deploy to Oracle Cloud](https://oci-resourcemanager-plugin.plugins.oci.oraclecloud.com/latest/deploy-to-oracle-cloud.svg)](https://cloud.oracle.com/resourcemanager/stacks/create?zipUrl=https://github.com/oracle-devrel/technology-engineering/releases/download/oke-rm-1.1.6/oke.zip)
2626

2727
Also note that if the network infrastructure is located in a different compartment than the OKE cluster AND you are planning to use the OCI_VCN_NATIVE CNI,
2828
you must add these policies:
1.25 KB
Binary file not shown.

app-dev/devops-and-containers/oke/oke-rm/infra/modules/network/bastion-sl.tf

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,50 @@ resource "oci_core_security_list" "bastion_security_list" {
22
compartment_id = var.network_compartment_id
33
vcn_id = local.vcn_id
44
display_name = "bastion-sec-list"
5+
6+
# Ingress rules and their corresponding egress
57
ingress_security_rules {
68
protocol = local.tcp_protocol
79
source_type = "CIDR_BLOCK"
810
source = "0.0.0.0/0"
11+
stateless = true
912
description = "Allow SSH connections to the subnet. Can be deleted if only using OCI Bastion subnet"
1013
tcp_options {
1114
max = 22
1215
min = 22
1316
}
1417
}
18+
19+
egress_security_rules {
20+
destination = "0.0.0.0/0"
21+
destination_type = "CIDR_BLOCK"
22+
protocol = local.tcp_protocol
23+
stateless = true
24+
description = "Allow SSH responses from the subnet"
25+
tcp_options {
26+
source_port_range {
27+
max = 22
28+
min = 22
29+
}
30+
}
31+
}
32+
33+
# Egress rules and their corresponding ingress
1534
egress_security_rules {
1635
destination = var.vcn_cidr_blocks[0]
1736
destination_type = "CIDR_BLOCK"
1837
protocol = "all"
38+
stateless = true
1939
description = "Enable the bastion hosts to reach the entire VCN"
2040
}
41+
42+
ingress_security_rules {
43+
protocol = "all"
44+
source_type = "CIDR_BLOCK"
45+
source = var.vcn_cidr_blocks[0]
46+
stateless = true
47+
description = "Allow responses from the VCN to the bastion hosts"
48+
}
49+
2150
count = var.create_bastion_subnet ? 1 : 0
22-
}
51+
}

0 commit comments

Comments
 (0)