Skip to content

Commit f389937

Browse files
authored
chore(helm): unify dependency enabler flag (#1361)
This commit - unifies dependency enabler flag.
1 parent 53f555f commit f389937

File tree

11 files changed

+22
-22
lines changed

11 files changed

+22
-22
lines changed

Makefile.helm

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ define HELM_INSTALL_INSTILL_CORE
5757
@helm install ${INSTILL_CORE_HELM_RELEASE_NAME} charts/core \
5858
--namespace ${INSTILL_CORE_KUBERNETES_NAMESPACE} --create-namespace \
5959
--set edition=$(if $(filter true,$(1)),k8s-ce:test,k8s-ce) \
60-
--set tags.observability=$(OBSERVE_ENABLED) \
60+
--set opentelemetry-collector.enabled=$(OBSERVE_ENABLED) \
6161
--set pipelineBackend.instillCoreHost=http://${INSTILL_CORE_HOST}:${API_GATEWAY_PORT} \
6262
--set artifactBackend.instillCoreHost=http://${INSTILL_CORE_HOST}:${API_GATEWAY_PORT} \
6363
--set modelBackend.instillCoreHost=http://${INSTILL_CORE_HOST}:${API_GATEWAY_PORT} \
@@ -72,7 +72,7 @@ define HELM_INSTALL_INSTILL_CORE
7272
$(if $(filter true,$(1)),--set 'pipelineBackend.extraEnv[0].value=foo',) \
7373
$(if $(filter true,$(1)),--set 'pipelineBackend.extraEnv[1].name=CFG_COMPONENT_SECRETS_GITHUB_OAUTHCLIENTSECRET',) \
7474
$(if $(filter true,$(1)),--set 'pipelineBackend.extraEnv[1].value=foo',) \
75-
--timeout 60s
75+
--timeout 300s
7676
endef
7777

7878
# Function to install observability stack
@@ -94,7 +94,7 @@ endef
9494

9595
# Function to remove observability stack
9696
define REMOVE_OBSERVABILITY
97-
@if helm list --namespace ${OBSERVABILITY_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "grafana" 2>/dev/null; then \
97+
@if helm list --namespace ${OBSERVABILITY_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "grafana\|tempo\|loki\|prometheus" || kubectl get namespace ${OBSERVABILITY_KUBERNETES_NAMESPACE} >/dev/null 2>&1; then \
9898
helm uninstall grafana --namespace ${OBSERVABILITY_KUBERNETES_NAMESPACE}; \
9999
helm uninstall tempo --namespace ${OBSERVABILITY_KUBERNETES_NAMESPACE}; \
100100
helm uninstall loki --namespace ${OBSERVABILITY_KUBERNETES_NAMESPACE}; \
@@ -106,7 +106,7 @@ endef
106106

107107
# Function to remove Milvus
108108
define REMOVE_MILVUS
109-
@if helm list --namespace ${MILVUS_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "milvus-operator" 2>/dev/null; then \
109+
@if helm list --namespace ${MILVUS_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "milvus-operator" || kubectl get namespace ${MILVUS_KUBERNETES_NAMESPACE} >/dev/null 2>&1; then \
110110
kubectl delete -f configs/helm/milvus/manifests; \
111111
helm uninstall milvus-operator --namespace ${MILVUS_KUBERNETES_NAMESPACE}; \
112112
kubectl delete namespace ${MILVUS_KUBERNETES_NAMESPACE}; \
@@ -115,7 +115,7 @@ endef
115115

116116
# Function to remove MinIO
117117
define REMOVE_MINIO
118-
@if helm list --namespace ${MINIO_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "operator" 2>/dev/null; then \
118+
@if helm list --namespace ${MINIO_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "operator\|tenant" || kubectl get namespace ${MINIO_KUBERNETES_NAMESPACE} >/dev/null 2>&1; then \
119119
helm uninstall operator --namespace ${MINIO_KUBERNETES_NAMESPACE}; \
120120
helm uninstall tenant --namespace ${MINIO_KUBERNETES_NAMESPACE}; \
121121
kubectl delete namespace ${MINIO_KUBERNETES_NAMESPACE}; \
@@ -124,15 +124,15 @@ endef
124124

125125
# Function to remove Temporal
126126
define REMOVE_TEMPORAL
127-
@if helm list --namespace ${TEMPORAL_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "temporal" 2>/dev/null; then \
127+
@if helm list --namespace ${TEMPORAL_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "temporal" || kubectl get namespace ${TEMPORAL_KUBERNETES_NAMESPACE} >/dev/null 2>&1; then \
128128
helm uninstall temporal --namespace ${TEMPORAL_KUBERNETES_NAMESPACE}; \
129129
kubectl delete namespace ${TEMPORAL_KUBERNETES_NAMESPACE}; \
130130
fi
131131
endef
132132

133133
# Function to remove Ray
134134
define REMOVE_RAY
135-
@if helm list --namespace ${RAY_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "ray" 2>/dev/null; then \
135+
@if helm list --namespace ${RAY_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "ray-operator" || kubectl get namespace ${RAY_KUBERNETES_NAMESPACE} >/dev/null 2>&1; then \
136136
helm uninstall ray-operator --namespace ${RAY_KUBERNETES_NAMESPACE}; \
137137
kubectl delete -f configs/helm/ray/manifests; \
138138
kubectl delete namespace ${RAY_KUBERNETES_NAMESPACE}; \
@@ -142,7 +142,7 @@ endef
142142

143143
# Function to remove Instill Core
144144
define REMOVE_INSTILL_CORE
145-
@if helm list --namespace ${INSTILL_CORE_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "${INSTILL_CORE_HELM_RELEASE_NAME}" 2>/dev/null; then \
145+
@if helm list --namespace ${INSTILL_CORE_KUBERNETES_NAMESPACE} 2>/dev/null | grep -q "${INSTILL_CORE_HELM_RELEASE_NAME}" || kubectl get namespace ${INSTILL_CORE_KUBERNETES_NAMESPACE} >/dev/null 2>&1; then \
146146
helm uninstall ${INSTILL_CORE_HELM_RELEASE_NAME} --namespace ${INSTILL_CORE_KUBERNETES_NAMESPACE}; \
147147
kubectl delete namespace ${INSTILL_CORE_KUBERNETES_NAMESPACE}; \
148148
ps aux | grep "[k]ubectl port-forward" | awk '{print $$2}' | xargs -r kill -9 2>/dev/null || true; \

charts/core/Chart.lock

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@ dependencies:
88
- name: opentelemetry-collector
99
repository: https://open-telemetry.github.io/opentelemetry-helm-charts
1010
version: 0.129.0
11-
digest: sha256:c79b3e4acdc9c34cfd88f05c55fb7c99bc278d9679d4177eda9e6ea42e5a662e
12-
generated: "2025-08-04T23:52:41.027391+01:00"
11+
digest: sha256:a1a7c83d0c2933c78b94faf9f497f719138f2f7c359358691a9cbc438475ab2c
12+
generated: "2025-08-05T22:45:15.203595+01:00"

charts/core/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@ dependencies:
2121
- name: openfga
2222
repository: https://openfga.github.io/helm-charts
2323
version: 0.2.39
24+
condition: openfga.enabled
2425
- name: influxdb2
2526
repository: https://helm.influxdata.com
2627
version: 2.1.1
2728
condition: influxdb2.enabled
2829
- name: opentelemetry-collector
2930
repository: https://open-telemetry.github.io/opentelemetry-helm-charts
3031
version: 0.129.0
31-
tags:
32-
- observability
32+
condition: opentelemetry-collector.enabled

charts/core/templates/api-gateway/configmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ data:
88
LOG_LEVEL={{ upper .Values.logLevel }}
99
1010
# Enable observability stack
11-
OBSERVE_ENABLED={{ .Values.tags.observability }}
11+
OBSERVE_ENABLED={{ index .Values "opentelemetry-collector" "enabled" }}
1212
1313
# Service version
1414
SERVICE_VERSION={{ .Values.apiGateway.image.tag }}

charts/core/templates/artifact-backend/configmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ data:
5454
cert:
5555
key:
5656
otelcollector:
57-
enable: {{ .Values.tags.observability }}
57+
enable: {{ index .Values "opentelemetry-collector" "enabled" }}
5858
host: {{ include "core.otel" . }}
5959
port: {{ include "core.otel.port" . }}
6060
openfga:

charts/core/templates/grafana/configmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{{- if eq .Values.tags.observability true }}
1+
{{- if eq (index .Values "opentelemetry-collector" "enabled") true }}
22
kind: ConfigMap
33
apiVersion: v1
44
metadata:

charts/core/templates/grafana/secret.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{{- if eq .Values.tags.observability true }}
1+
{{- if eq (index .Values "opentelemetry-collector" "enabled") true }}
22
apiVersion: v1
33
kind: Secret
44
metadata:

charts/core/templates/mgmt-backend/configmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ data:
6161
cert:
6262
key:
6363
otelcollector:
64-
enable: {{ .Values.tags.observability }}
64+
enable: {{ index .Values "opentelemetry-collector" "enabled" }}
6565
host: {{ include "core.otel" . }}
6666
port: {{ include "core.otel.port" . }}
6767
openfga:

charts/core/templates/model-backend/configmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ data:
2727
instillcorehost: {{ .Values.modelBackend.instillCoreHost }}
2828
taskschemaversion: {{ .Values.modelBackend.taskSchemaVersion }}
2929
otelcollector:
30-
enable: {{ .Values.tags.observability }}
30+
enable: {{ index .Values "opentelemetry-collector" "enabled" }}
3131
host: {{ include "core.otel" . }}
3232
port: {{ include "core.otel.port" . }}
3333
mgmtbackend:

charts/core/templates/pipeline-backend/configmap.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ data:
9494
insecureskipverify: {{ default "true" .Values.pipelineBackend.temporal.insecureSkipVerify }}
9595
metricsport: 9090
9696
otelcollector:
97-
enable: {{ .Values.tags.observability }}
97+
enable: {{ index .Values "opentelemetry-collector" "enabled" }}
9898
host: {{ include "core.otel" . }}
9999
port: {{ include "core.otel.port" . }}
100100
openfga:

0 commit comments

Comments
 (0)