Skip to content

Commit 87685f9

Browse files
authored
chore: add more dev docs (#14)
1 parent c3c1c60 commit 87685f9

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

README.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,44 @@ To deploy a local build, either initial install to update an existing deployment
1313

1414
```shell
1515
make dev.run-on-kind
16+
eval $(make kind.kubeconfig)
17+
```
18+
19+
To create a cluster with [clusterctl](https://cluster-api.sigs.k8s.io/user/quick-start.html), run:
20+
21+
```shell
22+
clusterctl generate cluster capi-quickstart \
23+
--flavor development \
24+
--kubernetes-version v1.26.0 \
25+
--control-plane-machine-count=1 \
26+
--worker-machine-count=1 | \
27+
kubectl apply -f -
28+
```
29+
30+
Label the cluster to deploy Calico:
31+
32+
```shell
33+
kubectl label cluster capi-quickstart capi-runtime-extensions.d2iq-labs.com/cni=calico
34+
```
35+
36+
To get the kubeconfig for the new cluster, run:
37+
38+
```shell
39+
clusterctl get kubeconfig capi-quickstart > capd-kubeconfig
40+
```
41+
42+
If you are not on Linux, you will also need to fix the generated kubeconfig's `server`, run:
43+
44+
```shell
45+
kubectl config set-cluster capi-quickstart \
46+
--kubeconfig capd-kubeconfig \
47+
--server=https://$(docker port capi-quickstart-lb 6443/tcp)
48+
```
49+
50+
To delete the workload cluster, run:
51+
52+
```shell
53+
kubectl delete cluster capi-quickstart
1654
```
1755

1856
To delete the dev KinD cluster, run:

0 commit comments

Comments
 (0)