Skip to content

Commit a3226a4

Browse files
committed
added documentation for new feature
1 parent 8028005 commit a3226a4

File tree

2 files changed

+99
-0
lines changed

2 files changed

+99
-0
lines changed

docs/src/gs/externally-managed-cluster-infrastructure.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,57 @@ spec:
4949
In the above spec, note that name has to be mentioned for Subnet/NSG. This is so that Kubernetes
5050
can merge the list properly when there is an update.
5151
52+
53+
54+
## Example spec for externally managed VCN, Subnet and Gateways, but the other networking components self managed
55+
56+
57+
Example spec is given below
58+
59+
```yaml
60+
apiVersion: infrastructure.cluster.x-k8s.io/v1beta2
61+
kind: OCICluster
62+
metadata:
63+
name: "${CLUSTER_NAME}"
64+
spec:
65+
compartmentId: "${OCI_COMPARTMENT_ID}"
66+
networkSpec:
67+
vcn:
68+
skip: true
69+
id: <Insert VCN OCID Here>
70+
networkSecurityGroup:
71+
skip: false
72+
internetGateway:
73+
skip: true
74+
natGateway:
75+
skip: true
76+
serviceGateway:
77+
skip: true
78+
routeTable:
79+
skip: true
80+
subnets:
81+
- id: <Insert control Plane Subnet OCID Here>
82+
role: control-plane-endpoint
83+
name: control-plane-endpoint
84+
type: public
85+
skip: true
86+
- id: <Insert control Plane Subnet OCID Here>
87+
role: worker
88+
name: worker
89+
type: private
90+
skip: true
91+
- id: <Insert control Plane Subnet OCID Here>
92+
role: control-plane
93+
name: control-plane
94+
type: private
95+
skip: true
96+
- id: <Insert control Plane Subnet OCID Here>
97+
role: service-lb
98+
name: service-lb
99+
type: public
100+
skip: true
101+
```
102+
52103
## Example `OCICluster` Spec with external infrastructure
53104

54105
CAPOCI supports [externally managed cluster infrastructure](https://github.com/kubernetes-sigs/cluster-api/blob/10d89ceca938e4d3d94a1d1c2b60515bcdf39829/docs/proposals/20210203-externally-managed-cluster-infrastructure.md).
@@ -93,6 +144,8 @@ spec:
93144
role: worker
94145
```
95146

147+
148+
96149
## Status
97150

98151
As per the Cluster API Provider specification, the `OCICluster Status` Object has to be updated with `ready` status

docs/src/managed/networking.md

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,52 @@ spec:
3939
type: public
4040
```
4141
42+
## Use a pre-existing VCN, Subnet and Gatways, but the other networking components self managed
43+
44+
The following `OCIManagedCluster` snippet can be used to to use a pre-existing VCN.
45+
46+
```yaml
47+
kind: OCIManagedCluster
48+
spec:
49+
compartmentId: "${OCI_COMPARTMENT_ID}"
50+
networkSpec:
51+
skipNetworkManagement: true
52+
vcn:
53+
skip: true
54+
id: <Insert VCN OCID Here>
55+
networkSecurityGroup:
56+
skip: false
57+
internetGateway:
58+
skip: true
59+
natGateway:
60+
skip: true
61+
serviceGateway:
62+
skip: true
63+
routeTable:
64+
skip: true
65+
subnets:
66+
- id: <Insert control Plane Subnet OCID Here>
67+
role: control-plane-endpoint
68+
name: control-plane-endpoint
69+
type: public
70+
skip: true
71+
- id: <Insert control Plane Subnet OCID Here>
72+
role: worker
73+
name: worker
74+
type: private
75+
skip: true
76+
- id: <Insert control Plane Subnet OCID Here>
77+
role: control-plane
78+
name: control-plane
79+
type: private
80+
skip: true
81+
- id: <Insert control Plane Subnet OCID Here>
82+
role: service-lb
83+
name: service-lb
84+
type: public
85+
skip: true
86+
```
87+
4288
## Use flannel as CNI
4389

4490
Use the template `cluster-template-managed-flannel.yaml` as an example for using flannel as the CNI. The template

0 commit comments

Comments
 (0)