diff --git a/packages/core/installer/templates/cozystack-operator.yaml b/packages/core/installer/templates/cozystack-operator.yaml index a88b2590..31028757 100644 --- a/packages/core/installer/templates/cozystack-operator.yaml +++ b/packages/core/installer/templates/cozystack-operator.yaml @@ -65,9 +65,9 @@ spec: {{- end }} env: - name: KUBERNETES_SERVICE_HOST - value: localhost + value: {{ .Values.cozystackOperator.kubernetesServiceHost | quote }} - name: KUBERNETES_SERVICE_PORT - value: "7445" + value: {{ .Values.cozystackOperator.kubernetesServicePort | quote }} hostNetwork: true tolerations: - key: "node.kubernetes.io/not-ready" diff --git a/packages/core/platform/templates/bundles/system.yaml b/packages/core/platform/templates/bundles/system.yaml index 96a88333..f683bf03 100644 --- a/packages/core/platform/templates/bundles/system.yaml +++ b/packages/core/platform/templates/bundles/system.yaml @@ -11,6 +11,11 @@ "SVC_CIDR" .Values.networking.serviceCIDR "JOIN_CIDR" .Values.networking.joinCIDR)) -}} {{- $_ := set $networkingComponents "kubeovn" (dict "values" $kubeovnValues) -}} +{{- $ciliumValues := dict "cilium" (dict + "k8sServiceHost" .Values.networking.apiServer.host + "k8sServicePort" .Values.networking.apiServer.port + "cgroup" (dict "autoMount" (dict "enabled" .Values.networking.cilium.cgroup.autoMount))) -}} +{{- $_ := set $networkingComponents "cilium" (dict "values" $ciliumValues) -}} {{- end -}} {{include "cozystack.platform.package" (list "cozystack.networking" "kubeovn-cilium" $ $networkingComponents) }} {{include "cozystack.platform.package.default" (list "cozystack.kubeovn-webhook" $) }} diff --git a/packages/core/platform/values.yaml b/packages/core/platform/values.yaml index f8a0a9e4..4665e86b 100644 --- a/packages/core/platform/values.yaml +++ b/packages/core/platform/values.yaml @@ -27,6 +27,16 @@ networking: podGateway: "10.244.0.1" serviceCIDR: "10.96.0.0/16" joinCIDR: "100.64.0.0/16" + # Kubernetes API server configuration for Cilium + # Defaults are for Talos KubePrism; override for non-Talos clusters + apiServer: + host: "localhost" + port: "7445" + # Cilium cgroup configuration + # Set autoMount to true for non-Talos clusters + cilium: + cgroup: + autoMount: false # Service publishing and ingress configuration publishing: host: "example.org"