Skip to content

Commit

Permalink
add helm for kind (#57)
Browse files Browse the repository at this point in the history
  • Loading branch information
johnlanni authored Nov 14, 2022
1 parent b15604e commit 8165ea6
Show file tree
Hide file tree
Showing 14 changed files with 86 additions and 8 deletions.
6 changes: 6 additions & 0 deletions Makefile.core.mk
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,12 @@ helm-push-istio:
cd helm/istio; helm dependency update
cd helm; tar -zcf istio.tgz istio; helm push istio.tgz "oci://$(CHARTS)"

helm-push-kind:
cd helm/kind/higress; helm dependency update
cd helm/kind; tar -zcf higress.tgz higress; helm push higress.tgz "oci://$(CHARTS)"
cd helm/kind/istio; helm dependency update
cd helm/kind; tar -zcf istio.tgz istio; helm push istio.tgz "oci://$(CHARTS)"


DIRS_TO_CLEAN := $(OUT)
DIRS_TO_CLEAN += $(OUT_LINUX)
Expand Down
4 changes: 2 additions & 2 deletions helm/higress/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
apiVersion: v2
appVersion: 0.5.1
appVersion: 0.5.2
description: Helm chart for deploying higress gateways
icon: https://higress.io/img/higress_logo_small.png
keywords:
Expand All @@ -9,4 +9,4 @@ name: higress
sources:
- http://github.com/alibaba/higress
type: application
version: 0.5.1
version: 0.5.2
2 changes: 2 additions & 0 deletions helm/higress/templates/controller-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,10 @@ spec:
{{- end }}
readinessProbe:
{{- toYaml .Values.controller.probe | nindent 12 }}
{{- if not .Values.global.kind }}
resources:
{{- toYaml .Values.controller.resources | nindent 12 }}
{{- end }}
{{- with .Values.controller.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
Expand Down
16 changes: 16 additions & 0 deletions helm/higress/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,11 @@ metadata:
{{- .Values.gateway.annotations | toYaml | nindent 4 }}
spec:
{{- if not .Values.gateway.autoscaling.enabled }}
{{- if not .Values.global.kind }}
replicas: {{ .Values.gateway.replicaCount }}
{{- else }}
replicas: 1
{{- end }}
{{- end }}
selector:
matchLabels:
Expand Down Expand Up @@ -137,6 +141,16 @@ spec:
- containerPort: 15090
protocol: TCP
name: http-envoy-prom
{{- if .Values.global.kind }}
- containerPort: 80
hostPort: 80
name: http
protocol: TCP
- containerPort: 443
hostPort: 443
name: https
protocol: TCP
{{- end }}
readinessProbe:
failureThreshold: 30
httpGet:
Expand All @@ -147,8 +161,10 @@ spec:
periodSeconds: 2
successThreshold: 1
timeoutSeconds: 3
{{- if not .Values.global.kind }}
resources:
{{- toYaml .Values.gateway.resources | nindent 12 }}
{{- end }}
volumeMounts:
- name: config
mountPath: /etc/istio/config
Expand Down
5 changes: 3 additions & 2 deletions helm/higress/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ global:
# whether to use autoscaling/v2 template for HPA settings
# for internal usage only, not to be configured by users.
autoscalingv2API: true
kind: false
hub: higress-registry.cn-hangzhou.cr.aliyuncs.com/higress
ingressClass: ""
watchNamespace: ""
Expand All @@ -13,7 +14,7 @@ gateway:
name: "higress-gateway"
replicaCount: 2
image: gateway
tag: "04cfef254aade907478c2b70cf576bb5eb310047"
tag: "268c73301e78514552fe0576fb0059c42c854a5c"
# revision declares which revision this gateway is a part of
revision: ""

Expand Down Expand Up @@ -104,7 +105,7 @@ controller:
name: "higress-controller"
replicaCount: 1
image: higress
tag: "04cfef254aade907478c2b70cf576bb5eb310047"
tag: "268c73301e78514552fe0576fb0059c42c854a5c"
env: {}
replicaCount: 1

Expand Down
4 changes: 2 additions & 2 deletions helm/istio/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
apiVersion: v2
appVersion: 1.12.1
appVersion: 1.12.2
description: Helm chart for deploying higress istio
name: istio
sources:
Expand All @@ -12,4 +12,4 @@ dependencies:
repository: "file://../istiod"
version: 1.12.0
type: application
version: 1.12.1
version: 1.12.2
2 changes: 2 additions & 0 deletions helm/istiod/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -159,12 +159,14 @@ spec:
value: "{{ .Values.global.istiod.enableAnalysis }}"
- name: CLUSTER_ID
value: "{{ $.Values.global.multiCluster.clusterName | default `Kubernetes` }}"
{{- if not .Values.global.kind }}
resources:
{{- if .Values.pilot.resources }}
{{ toYaml .Values.pilot.resources | trim | indent 12 }}
{{- else }}
{{ toYaml .Values.global.defaultResources | trim | indent 12 }}
{{- end }}
{{- end }}
securityContext:
readOnlyRootFilesystem: true
runAsUser: 1337
Expand Down
5 changes: 3 additions & 2 deletions helm/istiod/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ pilot:
rollingMaxUnavailable: 25%

hub: higress-registry.cn-hangzhou.cr.aliyuncs.com/higress
tag: 04cfef254aade907478c2b70cf576bb5eb310047
tag: 268c73301e78514552fe0576fb0059c42c854a5c

# Can be a full hub/image:tag
image: pilot
Expand Down Expand Up @@ -221,6 +221,7 @@ meshConfig:
# No hurry to do this in 1.6, we're trying to prove the code.

global:
kind: false
# whether to use autoscaling/v2 template for HPA settings
# for internal usage only, not to be configured by users.
autoscalingv2API: true
Expand Down Expand Up @@ -253,7 +254,7 @@ global:
# Dev builds from prow are on gcr.io
hub: higress-registry.cn-hangzhou.cr.aliyuncs.com/higress
# Default tag for Istio images.
tag: 1.12
tag: 268c73301e78514552fe0576fb0059c42c854a5c

# Specify image pull policy if default behavior isn't desired.
# Default behavior: latest images will be Always else IfNotPresent.
Expand Down
6 changes: 6 additions & 0 deletions helm/kind/higress/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
dependencies:
- name: higress
repository: file://../../higress
version: 0.5.2
digest: sha256:414ef7a78a25d8f25d1f643edf4c8e59f74ecaa51a5ae4e4bff3000472b08fdb
generated: "2022-11-13T13:39:25.948896+08:00"
16 changes: 16 additions & 0 deletions helm/kind/higress/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
apiVersion: v2
appVersion: 0.5.2
description: Helm chart for deploying higress gateways
icon: https://higress.io/img/higress_logo_small.png
keywords:
- higress
- gateways
name: higress-local
sources:
- http://github.com/alibaba/higress
dependencies:
- name: higress
repository: "file://../../higress"
version: 0.5.2
type: application
version: 0.5.2
2 changes: 2 additions & 0 deletions helm/kind/higress/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
global:
kind: true
9 changes: 9 additions & 0 deletions helm/kind/istio/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
dependencies:
- name: base
repository: file://../../base
version: 1.12.0
- name: istiod
repository: file://../../istiod
version: 1.12.0
digest: sha256:ce57290cabf7b0a85a150017cfdfcb2e25f18de7e8c93f5f3020750f9a65ece3
generated: "2022-11-13T13:50:54.129765+08:00"
15 changes: 15 additions & 0 deletions helm/kind/istio/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: v2
appVersion: 1.12.2
description: Helm chart for deploying higress istio
name: istio-local
sources:
- http://github.com/alibaba/higress
dependencies:
- name: base
repository: "file://../../base"
version: 1.12.0
- name: istiod
repository: "file://../../istiod"
version: 1.12.0
type: application
version: 1.12.2
2 changes: 2 additions & 0 deletions helm/kind/istio/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
global:
kind: true

0 comments on commit 8165ea6

Please sign in to comment.