Skip to content

Commit 0722e35

Browse files
authored
Merge pull request #170 from camjay/feat/gateway-dataservice-parity
feat(deployment): gateway/dataservice feature parity
2 parents a567737 + 3593ac8 commit 0722e35

3 files changed

Lines changed: 40 additions & 1 deletion

File tree

charts/portkey-gateway/templates/dataservice/deployment.yaml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,10 @@ spec:
4141
{{- toYaml . | nindent 8 }}
4242
{{- end }}
4343
spec:
44-
imagePullSecrets:
44+
{{- if hasKey .Values.dataservice.deployment "terminationGracePeriodSeconds" }}
45+
terminationGracePeriodSeconds: {{ .Values.dataservice.deployment.terminationGracePeriodSeconds }}
46+
{{- end }}
47+
imagePullSecrets:
4548
{{- range .Values.imageCredentials }}
4649
- name: {{ .name }}
4750
{{- end }}
@@ -54,6 +57,10 @@ spec:
5457
command:
5558
{{- toYaml . | nindent 12 }}
5659
{{- end }}
60+
{{- if .Values.dataservice.envFrom }}
61+
envFrom:
62+
{{- toYaml .Values.dataservice.envFrom | nindent 12 }}
63+
{{- end }}
5764
env:
5865
- name: GATEWAY_BASE_URL
5966
value: http://{{ include "portkeyenterprise.fullname" . }}:{{ .Values.service.port }}

charts/portkey-gateway/templates/gateway/deployment.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,23 @@ spec:
6868
containerPort: {{ include "mcp.containerPort" . }}
6969
protocol: TCP
7070
{{- end }}
71+
{{- if .Values.envFrom }}
72+
envFrom:
73+
{{- toYaml .Values.envFrom | nindent 12 }}
74+
{{- end }}
7175
env:
7276
{{- if .Values.dataservice.enabled }}
7377
- name: DATASERVICE_BASEPATH
7478
value: http://{{ include "portkeyenterprise.fullname" . }}-{{ .Values.dataservice.name }}:{{ .Values.dataservice.service.port }}
7579
{{- end }}
7680
{{- include "portkeyenterprise.commonEnv" . | nindent 12 }}
81+
{{- with .Values.extraEnv }}
82+
{{- toYaml . | nindent 12 }}
83+
{{- end }}
84+
{{- with .Values.startupProbe }}
85+
startupProbe:
86+
{{- toYaml . | nindent 12 }}
87+
{{- end }}
7788
livenessProbe:
7889
{{- toYaml .Values.livenessProbe | nindent 12 }}
7990
readinessProbe:

charts/portkey-gateway/values.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -214,6 +214,17 @@ resources: {}
214214
# cpu: 100m
215215
# memory: 128Mi
216216

217+
# startupProbe is optional and rendered only when defined.
218+
# Useful for slow-starting containers to avoid premature liveness kills.
219+
# Example:
220+
# startupProbe:
221+
# httpGet:
222+
# path: /v1/health
223+
# port: 8787
224+
# initialDelaySeconds: 10
225+
# periodSeconds: 5
226+
# failureThreshold: 30
227+
217228
livenessProbe:
218229
httpGet:
219230
path: /v1/health
@@ -263,6 +274,14 @@ volumeMounts: []
263274

264275
extraContainerConfig: {}
265276

277+
# envFrom allows loading all keys from secrets/configmaps as environment variables.
278+
# Useful for external secret managers (ESO, Vault CSI, AWS Secrets Manager).
279+
# Variables in env (from environment.data) take precedence over envFrom.
280+
envFrom: []
281+
282+
# Additional environment variables appended after commonEnv.
283+
extraEnv: []
284+
266285
# Additional sidecar containers injected into the gateway pod.
267286
# Each entry is a full Kubernetes container spec.
268287
# Example: nginx TLS-termination sidecar
@@ -318,12 +337,14 @@ dataservice:
318337
containerPort: 8081
319338
finetuneBucket: ""
320339
logexportsBucket: ""
340+
envFrom: []
321341
env:
322342
DEBUG_ENABLED: false
323343
SERVICE_NAME: "portkeyenterprise-dataservice"
324344
deployment:
325345
autoRestart: true
326346
replicas: 1
347+
# terminationGracePeriodSeconds: 30
327348
labels: {}
328349
selectorLabels: {}
329350
annotations: {}

0 commit comments

Comments
 (0)