vcluster

by Bedag Informatik AG

Helm chartv0.17.1App 0.1.0Verified publisher

Virtual Kubernetes Cluster

About this chart

Vcluster

This Chart is under active development! We try to improve documentation and values consistency over time

Virtual Kubernetes Cluster

Homepage: https://artifacthub.io/packages/helm/kvaps/kubernetes

Maintainers

NameEmailUrl
Bedag Informatik AG[email protected]

Major Changes

Major Changes to functions are documented with the version affected. Before upgrading the dependency version, check this section out!

ChangeChart VersionDescriptionCommits/PRs

Guides

Components

This chart contains different "components" (it's different tools which make up the control plane). The purpose of the combination if these tools is to achieve a control plane, which is easy to manage and does not relay on worker nodes to be managed. But we also do not intend to add a lot of complexity to the control plane. All the components are deployed as pods in the hosting cluster and are toggled by the enabled flag.

Kubernetes

Installs the required components to provide a Kubernetes Control Plane (hosted in pods). The implementation is based on Kuebrnetes by Kvaps, who came uup with this great idea.

Machine Controller

We recommend using our set version and configured flags

The Machine-Controller by Kubermatic.

Operating System Manager

We recommend using our set version and configured flags. The component is not stable tested yet!

The Operating System Manager by Kubermatic is responsible for creating and managing the required configurations for worker nodes in a Kubernetes cluster. It decouples operating system configurations into dedicated and isolable resources for better modularity and maintainability. It's optional and only works together with Machine Controller. If you enable this component, we will take care of the configuration between Machine-Controller and Operating System Manager.

Kubernetes

Installs the required components to provide a Kubernetes Control Plane (hosted in pods). The implementation is based on Kuebrnetes by Kvaps, who came uup with this great idea.

Kubernetes Autoscaler

Based on Cluster Autoscaler. Allows to scale Kubernetes clusters based on the number of pods and nodes. The component is deployed as a single deployment with a controller container. Since it's deployed on a hosting cluster, it's possible to downscale workers to zero and scale up again.

Guides

Exposure

Admission

Values

Globals


Global Values

KeyTypeDefaultDescription
global.components.exposure.certificates.issuer.kindstring"Issuer"Set if the cert manager will generate either self-signed or CA signed SSL certificates. Its value will be either Issuer or ClusterIssuer
global.components.exposure.certificates.issuer.namestring""Set the name of the ClusterIssuer if issuer kind is ClusterIssuer and if cert manager will generate CA signed SSL certificates
global.components.exposure.certificates.issuer.selfSignedbooltrueCreates self-signed Issuer
global.components.exposure.certificates.secretNamestring""Uses Existing Secret for all certificates
global.components.exposure.exposestring"loadbalancer"Define how admission webhooks are expose (ingress or loadbalancer). Overwrites expose for all admission webhooks.
global.components.exposure.ingress.annotationsobject{}Common annotations for admission ingresses
global.components.exposure.ingress.hoststring"{{ include \"pkg.cluster.name\" $ }}.example.com"Host for admission ingresses (admission endpoints are exposed via path). supports templating
global.components.exposure.ingress.ingressClassNamestring""Ingressclass for admission ingresses
global.components.exposure.ingress.portint443Port for Ingresses
global.components.metricsobject{}
global.components.networkPolicy.enabledboolfalseEnable NetworkPolicies
global.components.networkPolicy.fromlist[]Add from block for networkPolicies (by default from anywhere)
global.components.service.annotationsobject{}Annotations for all services
global.components.service.labelsobject{}Labels for all services
global.components.workloads.affinityobject{}Affinity for all workloads (Overwrites all workloads affinities)
global.components.workloads.annotationsobject{}Annotations for all workloads (merged with workload annotations)
global.components.workloads.image.pullPolicystring""Overwrites Pull Policy for all components
global.components.workloads.image.pullSecretslist[]Additional image pull secrets for all components
global.components.workloads.labelsobject{}Labels for all workloads (merged with workload labels)
global.components.workloads.nodeSelectorobject{}Node Selector for all workloads (Overwrites all workloads nodeSelector)
global.components.workloads.podAnnotationsobject{}Pod Annotations for all workloads (merged with workload podAnnotations)
global.components.workloads.podLabelsobject{}Pod Labels for all workloads (merged with workload podLabels)
global.components.workloads.podSecurityContextobject{"enabled":false}Pod Security Context for all workloads (Overwrites per workload podSecurityContext)
global.components.workloads.priorityClassNamestring""Priority Class for all workloads (Overwrites all workloads priorityClassNames)
global.components.workloads.securityContextobject{"enabled":false}Container Security Context for all workloads (Overwrites per workload securityContext)
global.components.workloads.tolerationslist[]Tolerations for all workloads (Overwrites all workloads tolerations)
global.components.workloads.topologySpreadConstraintslist[]TopologySpreadConstraints for all workloads (Overwrites all workloads topologySpreadConstraints)
global.proxy.hoststring""Proxy Host
global.proxy.no_proxystring"10.0.0.0/8"No Proxy Hosts
global.registries.primaryobject{"creds":{"password":"","username":""},"endpoint":""}Default Registry (used for kubeadm, regcred secret etc.)
global.registries.primary.creds.passwordstring""Registry Password
global.registries.primary.creds.usernamestring""Registry Username
global.registries.primary.endpointstring""Registry Endpoint
global.registries.secondariesobject{}Additional Registries (used in regcred secret)
global.storageClassNamestring""StorageClassName for all persistent volumes

Utilities Values


KeyTypeDefaultDescription
cluster.namestringThe cluster name is derived from the .Release.NameDefine the cluster name
cluster.propertiesobject{}Properties are substituted into the gitops component

Lifecycle


We use a lifecycle Job/Cronjob to manage certain configurations within the vcluster and the hosting cluster.

KeyTypeDefaultDescription
lifecycle.argocd.namespacestring"argocd"Installation namespace of ArgoCD
lifecycle.argocd.rbacbooltrueCreates required rbac in argoCD namespace to create cluster secrets
lifecycle.cilium.bgpControlPlaneobject{"enabled":true}Enable BGP Control Plane feature
lifecycle.cilium.devicesstring""Specify which network interfaces can run the eBPF datapath
lifecycle.cilium.enabledbooltrueInstall Cilium CNI
lifecycle.cilium.on_installbooltrueInstall only on chart install (First install)
lifecycle.cilium.versionstring"1.9.18"Cilium version
lifecycle.cleanup.annotationsobject{"helm.sh/hook":"pre-delete","helm.sh/hook-delete-policy":"before-hook-creation"}Job Annotations
lifecycle.cleanup.enabledboolfalseEnable/Disable Cleanup
lifecycle.cleanup.labelsobject{}Job Labels
lifecycle.current.extraManifestsobjectSee values.yamlThese manifests will be applied inside the cluster (supports templating)
lifecycle.current.extraManifestsOnInstallobjectSee values.yamlThese manifests will be applied inside the cluster, but only on $.Release.Install and wont be touched again (supports templating)
lifecycle.jobs.affinityobject{}Affinity
lifecycle.jobs.connectivity.image.digeststring""Image Digest
lifecycle.jobs.connectivity.image.pullPolicystring"IfNotPresent"Image pull policy
lifecycle.jobs.connectivity.image.pullSecretslist[]Image pull Secrets
lifecycle.jobs.connectivity.image.registrystring"ghcr.io"Image registry
lifecycle.jobs.connectivity.image.repositorystring"kvaps/kubernetes-tools"Image repository
lifecycle.jobs.connectivity.image.tagstring"v0.13.4"Image tag
lifecycle.jobs.connectivity.resourcesobject{}Resources configuration
lifecycle.jobs.connectivity.securityContextobject{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"enabled":true,"privileged":false,"runAsGroup":20000,"runAsUser":20000}Container Security Context
lifecycle.jobs.extraEnvlist[]Additional Pod Environment variables
lifecycle.jobs.extraVolumeMountslist[]Additional Pod VolumeMounts
lifecycle.jobs.extraVolumeslist[]Additional Pod Volumes
lifecycle.jobs.nodeSelectorobject{}Node Selector
lifecycle.jobs.podAnnotationsobject{}Pod Annotations
lifecycle.jobs.podLabelsobject{}Pod Labels
lifecycle.jobs.podSecurityContextobject{"enabled":true,"runAsNonRoot":true,"seccompProfile":{"type":"RuntimeDefault"}}Pod Security Context
lifecycle.jobs.priorityClassNamestring""Pod PriorityClassName
lifecycle.jobs.resourcesobject{}Resources configuration
lifecycle.jobs.securityContextobject{"allowPrivilegeEscalation":false,"capabilities":{"drop":["ALL"]},"enabled":true,"privileged":false,"runAsGroup":20000,"runAsUser":20000}Container Security Context
lifecycle.jobs.tolerationslist[]Tolerations
lifecycle.jobs.topologySpreadConstraintslist[]TopologySpreadConstraints
lifecycle.serviceAccount.annotationsobject{}Annotations to add to the service account
lifecycle.serviceAccount.createbooltrueSpecifies whether a service account should be created
lifecycle.serviceAccount.namestring""The name of the service account to use. If not set and create is true, a name is generated using the fullname template
lifecycle.setup.annotationsobject{"helm.sh/hook":"post-install,post-upgrade","helm.sh/hook-delete-policy":"before-hook-creation"}Job Annotations
lifecycle.setup.cronjobbooltrueDeploy as Cronjob to run periodically
lifecycle.setup.failedJobsHistoryLimitint3Cronjob failed jobs history limit
lifecycle.setup.injectProxybooltrueInject Proxy as Environment Variables
lifecycle.setup.labelsobject{}Job Labels
lifecycle.setup.schedulestring"0 0 1 */6 *"Cronjob Schedule
lifecycle.setup.successfulJobsHistoryLimitint3Cronjob successful jobs history limit
lifecycle.setup.ttlSecondsAfterFinishedint120ttlSecondsAfterFinished for setup
lifecycle.vcluster.extraOnlineManifestslist[]List of URLs which will be applied inside the vcluster (supports templating)
lifecycle.vcluster.extraOnlineManifestsOnInstalllist[]List of URLs which will be applied inside the vcluster, but only on $.Release.Install and wont be touched again (supports templating)

Machine Values


Available Values for the Machine Controller Component. The component consists of a single deployment with a controller and admission container. Pod settings are therefor made for both subcomponents.

KeyTypeDefaultDescription
machine.affinityobject{}Affinity
machine.annotationsobject{}Annotations for Workload
machine.autoscaling.enabledboolfalseEnable Horizontal Pod Autoscaler
machine.autoscaling.maxReplicasint100Maximum available Replicas
machine.autoscaling.minReplicasint1Minimum available Replicas
machine.autoscaling.targetCPUUtilizationPercentageint80Benchmark CPU Usage
machine.autoscaling.targetMemoryUtilizationPercentagestringnilBenchmark Memory Usage
machine.component.ensureManifestsOnStartupbooltrueEnsure all components manifests are present on controller start (as initContainer)
machine.component.removeManifestsOnDisablebooltrueRemove all manifests on disable in the vcluster (Attention: When crds are deleted all crs will be deleted as well)
machine.connectivity.image.digeststring""Image Digest
machine.connectivity.image.pullPolicystring`"IfNotPr

Deploy vcluster with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has vcluster on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartvcluster is pinned at v0.17.1 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply