Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add a note about the default clusterclass and how to get it #114

Closed
wants to merge 1 commit into from

Conversation

faiq
Copy link
Contributor

@faiq faiq commented Aug 22, 2023

No description provided.

Comment on lines +26 to +32
Download the clusterclass quick start template:

```shell
wget https://github.com/kubernetes-sigs/cluster-api/releases/download/v1.5.0/clusterclass-quick-start.yaml
kubectl apply -f clusterclass-quick-start.yaml
```

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The clusterctl generate command below actually creates this ClusterClass so unless you want to create it manually for other reasons this step is unnecessary.

$ clusterctl generate cluster capi-quickstart --flavor development --kubernetes-version v1.27.2 --control-plane-machine-count=1 --worker-machine-count=1 | gojq --yaml-input --yaml-output '. | select(.kind=="ClusterClass")'

apiVersion: cluster.x-k8s.io/v1beta1
kind: ClusterClass
metadata:
  name: quick-start
  namespace: default
<SNIP>

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah I see what the problem is, the kubectl label messes up the YAML. Tested the following and it works - I'll push a new commit with this change to this PR (can always revert if you prefer to keep it this way):

clusterctl generate cluster capi-quickstart \
    --flavor development \
    --kubernetes-version v1.27.2 \
    --control-plane-machine-count=1 \
    --worker-machine-count=1 | \
  gojq --yaml-input --yaml-output \
    '. | (select(.kind=="Cluster").metadata.labels["capiext.labs.d2iq.io/cni"]|="calico")' | \
  kubectl apply --server-side -f -

Copy link
Member

@jimmidyson jimmidyson Aug 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On second thoughts, I'm going to merge #107 and could you test again please? I think that should have everything you need to get going without this change.

@faiq faiq closed this Aug 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants