-
Notifications
You must be signed in to change notification settings - Fork 192
packaging management components, clusterclass-based creation #2581
Conversation
Cluster Generation A/B Results: |
Codecov Report
@@ Coverage Diff @@
## main #2581 +/- ##
==========================================
+ Coverage 42.72% 42.75% +0.03%
==========================================
Files 404 405 +1
Lines 40151 40516 +365
==========================================
+ Hits 17153 17323 +170
- Misses 21386 21569 +183
- Partials 1612 1624 +12
Continue to review full report at Codecov.
|
bed9946
to
9fe902d
Compare
/test install-vc7 |
Cluster Generation A/B Results: |
9fe902d
to
e37bae2
Compare
Cluster Generation A/B Results: |
/test install-vc7 |
files following the naming convention clusterclass-xxx.yaml are treated as cluster class files and are excluded from the checksum computation. also - renamed function to use more inclusive language Signed-off-by: Vui Lam <vui@vmware.com>
* Enable CI on package-based-lcm branch Co-authored-by: Sai Bandi <saib@vmware.com> Co-authored-by: Anuj Chaudhari <anujc@vmware.com>
- installs dependencies Signed-off-by: Vui Lam <vui@vmware.com>
…azure, clusterclass-vsphere - Add base for clusterclass-docker - Add base for clusterclass-aws - Add base for clusterclass-azure - Add base for clusterclass-vsphere - Add clusterclass packages to package-values.yaml file -- Script to sync CC yaml changes into infra specific package directories -- Update cc yamls in cc packages upstream here are actually locations to various cc-specific ytt templates/overlays in pkg/v1/providers they are being brought over by the sync_cc.sh script. -- Minor makefile and kbld-config.yaml to unblock build of the management package repository -- Fix BASTION_HOST_ENABLED in cc -- Add resource rules to the service account -- Fix package-install name
also: Remove commented code from Azure ClusterClass
This change fixes a nesting issue for defaults in clusterclass variables. The default was set on the variable and not the openAPISchema for the variable. Effects aws, azure and vsphere
Adds a new ClusterClassSelector interface. This interface takes in the cluster config and determines what clusterclass to use and returns the name. Returns empty string if it can't determine the cluster class.
Signed-off-by: Vui Lam <vui@vmware.com>
…g is enabled - Refactored codebase to use more generic implementation for workload and management cluster creation - Return CCluster.yaml for workload clusterif user is providing legacy configuration file when and no customizations are performed by user - Always use ClusterClass based cluster creation for management-cluster deployment when `package-based-lcm` feature-flag is enabled
…-flag - Added 'features.cluster.auto-apply-generated-clusterclass-based-configuration' feature-flag to support this usecase.
Gate the cluster creation with ClusterClass with feature-flag `features.global.package-based-lcm` Authored-by: Anuj Chaudhari <anujc@vmware.com>
…-flag - Added 'features.cluster.auto-apply-generated-clusterclass-based-configuration' feature-flag to support this usecase.
e37bae2
to
9e13af4
Compare
/test install-vc7 |
Cluster Generation A/B Results: |
/test install-vc7 |
Files removed by ./packages/tkg-clusterclass/hack/sync-cc.sh /Users/fgold/go/src/github.com/vmware-tanzu/tanzu-framework/packages/tkg-clusterclass/hack/../../../pkg/v1/providers/infrastructure-aws/v1.2.0/cconly/base.yaml /Users/fgold/go/src/github.com/vmware-tanzu/tanzu-framework/packages/tkg-clusterclass/hack/../../../pkg/v1/providers/infrastructure-aws/v1.2.0/cconly/overlay.yaml /Users/fgold/go/src/github.com/vmware-tanzu/tanzu-framework/packages/tkg-clusterclass/hack/../../../pkg/v1/providers/infrastructure-vsphere/v1.1.0/cconly/base.yaml /Users/fgold/go/src/github.com/vmware-tanzu/tanzu-framework/packages/tkg-clusterclass/hack/../../../pkg/v1/providers/infrastructure-vsphere/v1.1.0/cconly/overlay.yaml /Users/fgold/go/src/github.com/vmware-tanzu/tanzu-framework/packages/tkg-clusterclass/hack/../../../pkg/v1/providers/infrastructure-azure/v1.0.1/cconly/base.yaml /Users/fgold/go/src/github.com/vmware-tanzu/tanzu-framework/packages/tkg-clusterclass/hack/../../../pkg/v1/providers/infrastructure-azure/v1.0.1/cconly/overlay.yaml ./hack/verify-dirty.sh Verify uncommitted files... The following files are uncommitted. Please commit them or add them to .gitignore: - packages/tkg-clusterclass-aws/bundle/config/upstream/aws-clusterclass.yaml - packages/tkg-clusterclass-azure/bundle/config/upstream/azure-clusterclass.yaml - packages/tkg-clusterclass-vsphere/bundle/config/upstream/overlay-windows.yaml - packages/tkg-clusterclass-vsphere/bundle/config/upstream/vsphere-clusterclass.yaml Diff: diff --git a/packages/tkg-clusterclass-aws/bundle/config/upstream/aws-clusterclass.yaml b/packages/tkg-clusterclass-aws/bundle/config/upstream/aws-clusterclass.yaml deleted file mode 100644 index 8e4f5b2d..00000000 --- a/packages/tkg-clusterclass-aws/bundle/config/upstream/aws-clusterclass.yaml +++ /dev/null @@ -1,49 +0,0 @@ -#@ load("@ytt:overlay", "overlay") -#@ load("@ytt:yaml", "yaml") -#@ load("@ytt:data", "data") - ---- -apiVersion: cluster.x-k8s.io/v1beta1 -kind: ClusterClass -metadata: - name: tkg-aws-clusterclass - namespace: default -spec: - controlPlane: - ref: - apiVersion: controlplane.cluster.x-k8s.io/v1beta1 - kind: KubeadmControlPlaneTemplate - name: tkg-aws-kcp - machineInfrastructure: - ref: - kind: AWSMachineTemplate - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - name: tkg-controlplane-aws-template - infrastructure: - ref: - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - kind: AWSClusterTemplate - name: tkg-aws-cluster-template - workers: - machineDeployments: - - class: tkg-worker - template: - bootstrap: - ref: - apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 - kind: KubeadmConfigTemplate - name: tkg-aws-bootstrap-worker-template - infrastructure: - ref: - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - kind: AWSMachineTemplate - name: tkg-aws-worker-template - variables: - - name: AWS_REGION - required: true - schema: - openAPIV3Schema: - type: string - #@ if data.values.AWS_REGION: - default: #@ data.values.AWS_REGION - #@ end diff --git a/packages/tkg-clusterclass-azure/bundle/config/upstream/azure-clusterclass.yaml b/packages/tkg-clusterclass-azure/bundle/config/upstream/azure-clusterclass.yaml deleted file mode 100644 index 2b10ed63..00000000 --- a/packages/tkg-clusterclass-azure/bundle/config/upstream/azure-clusterclass.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: cluster.x-k8s.io/v1beta1 -kind: ClusterClass -metadata: - name: tkg-azure-clusterclass - namespace: default -spec: - controlPlane: - ref: - apiVersion: controlplane.cluster.x-k8s.io/v1beta1 - kind: KubeadmControlPlaneTemplate - name: tkg-azure-kcp - machineInfrastructure: - ref: - kind: AzureMachineTemplate - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - name: tkg-controlplane-azure-template - infrastructure: - ref: - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - kind: AzureClusterTemplate - name: tkg-azure-cluster-template - workers: - machineDeployments: - - class: tkg-worker - template: - bootstrap: - ref: - apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 - kind: KubeadmConfigTemplate - name: tkg-azure-bootstrap-worker-template - infrastructure: - ref: - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - kind: AzureMachineTemplate - name: tkg-azure-worker-template diff --git a/packages/tkg-clusterclass-vsphere/bundle/config/upstream/overlay-windows.yaml b/packages/tkg-clusterclass-vsphere/bundle/config/upstream/overlay-windows.yaml deleted file mode 100644 index ecdf083c..00000000 --- a/packages/tkg-clusterclass-vsphere/bundle/config/upstream/overlay-windows.yaml +++ /dev/null @@ -1,58 +0,0 @@ -#@ load("@ytt:overlay", "overlay") -#@ load("@ytt:data", "data") - -#@ if data.values.IS_WINDOWS_WORKLOAD_CLUSTER: - -#@overlay/match by=overlay.subset({"kind":"ClusterClass"}) ---- -apiVersion: cluster.x-k8s.io/v1beta1 -kind: ClusterClass -metadata: - namespace: #@ data.values.NAMESPACE -spec: - controlPlane: - ref: - name: tkg-vsphere-kcp - machineInfrastructure: - ref: - name: tkg-vsphere-control-plane - machineHealthCheck: - #@ if data.values.ENABLE_MHC or data.values.ENABLE_MHC_CONTROL_PLANE: - nodeStartupTimeout: #@ data.values.NODE_STARTUP_TIMEOUT - unhealthyConditions: - - type: Ready - status: Unknown - timeout: #@ data.values.MHC_UNKNOWN_STATUS_TIMEOUT - - type: Ready - status: "False" - timeout: #@ data.values.MHC_FALSE_STATUS_TIMEOUT - #@ end - infrastructure: - ref: - name: tkg-vsphere-infrastructure - namespace: #@ data.values.NAMESPACE - workers: - machineDeployments: - #@overlay/match by=overlay.index(0) - - class: tkg-worker - machineHealthCheck: - #@ if data.values.ENABLE_MHC or data.values.ENABLE_MHC_WORKER_NODE: - nodeStartupTimeout: #@ data.values.NODE_STARTUP_TIMEOUT - unhealthyConditions: - - type: Ready - status: Unknown - timeout: #@ data.values.MHC_UNKNOWN_STATUS_TIMEOUT - - type: Ready - status: "False" - timeout: #@ data.values.MHC_FALSE_STATUS_TIMEOUT - #@ end - template: - bootstrap: - ref: - name: tkg-vsphere-md-0 - namespace: #@ data.values.NAMESPACE - infrastructure: - ref: - name: tkg-vsphere-worker - namespace: #@ data.values.NAMESPACE -#@ end diff --git a/packages/tkg-clusterclass-vsphere/bundle/config/upstream/vsphere-clusterclass.yaml b/packages/tkg-clusterclass-vsphere/bundle/config/upstream/vsphere-clusterclass.yaml deleted file mode 100644 index 1d7e199c..00000000 --- a/packages/tkg-clusterclass-vsphere/bundle/config/upstream/vsphere-clusterclass.yaml +++ /dev/null @@ -1,35 +0,0 @@ -apiVersion: cluster.x-k8s.io/v1beta1 -kind: ClusterClass -metadata: - name: tkg-vsphere-clusterclass - namespace: default -spec: - controlPlane: - ref: - apiVersion: controlplane.cluster.x-k8s.io/v1beta1 - kind: KubeadmControlPlaneTemplate - name: tkg-vsphere-kcp - machineInfrastructure: - ref: - kind: VsphereMachineTemplate - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - name: tkg-controlplane-vsphere-template - infrastructure: - ref: - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - kind: VSphereClusterTemplate - name: tkg-vsphere-cluster-template - workers: - machineDeployments: - - class: tkg-worker - template: - bootstrap: - ref: - apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 - kind: KubeadmConfigTemplate - name: tkg-vsphere-bootstrap-worker-template - infrastructure: - ref: - apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 - kind: VsphereMachineTemplate - name: tkg-vsphere-worker-template Signed-off-by: F. Gold <fgold@vmware.com>
/test install-vc7 |
Cluster Generation A/B Results: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
What this PR does / why we need it
Changes pertaining to packaging management components and enabling cluster creation using a clusterclass based Cluster resource definition (CCluster.yaml)
Packaged and ClusterClass based cluster LCM
and some github workflow changes
Which issue(s) this PR fixes
Related-to #1339
Related-to #1340
Related-to #1341
Fixes #1531
Describe testing done for PR
Release note
PR Checklist
Additional information
Special notes for your reviewer