Skip to content

Commit

Permalink
Run createcachetable while starting the application
Browse files Browse the repository at this point in the history
  • Loading branch information
bartjkdp committed Jan 25, 2024
1 parent df9e344 commit bd36f65
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 3 deletions.
2 changes: 1 addition & 1 deletion charts/backend/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: backend
description: The API for the Signals application
type: application
version: 4.13.0
version: 4.13.1
appVersion: 2.34.1

dependencies:
Expand Down
28 changes: 28 additions & 0 deletions charts/backend/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,34 @@ spec:
{{- end }}
resources:
{{- toYaml .Values.resources | nindent 12 }}
- name: create-cache-table
securityContext:
{{- toYaml .Values.securityContext | nindent 12 }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
command:
- /usr/local/bin/python
args:
- '/app/manage.py'
- 'createcachetable'
env:
{{- range $key, $value := .Values.env }}
- name: {{ $key }}
value: {{ $value | quote }}
{{- end }}
{{- with .Values.envVars }}
{{- toYaml . | nindent 12 }}
{{- end }}
envFrom:
- configMapRef:
name: {{ template "signals-backend.fullname" . }}
- secretRef:
name: {{ if .Values.existingSecret }}{{ .Values.existingSecret }}{{ else }}{{ template "signals-backend.fullname" . }}{{ end }}
{{- with .Values.envFrom }}
{{- toYaml . | nindent 12 }}
{{- end }}
resources:
{{- toYaml .Values.resources | nindent 12 }}
containers:
- name: api
securityContext:
Expand Down
2 changes: 1 addition & 1 deletion charts/classification/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ apiVersion: v2
name: classification
description: Machine learning prediction API
type: application
version: 4.13.0
version: 4.13.1
appVersion: ad60447d1733473e30ab0a3ba53d58141cc1d250
2 changes: 1 addition & 1 deletion charts/frontend/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ apiVersion: v2
name: frontend
description: The web frontend for the Signals application
type: application
version: 4.13.0
version: 4.13.1
appVersion: 2.14.21

0 comments on commit bd36f65

Please sign in to comment.