1a195a96bd
- Merge origin/main into branch (resolve conflict in integrations_dashboard.html) - Add defensive JSON parsing with try/except for integration.config - Wrap tester() call in try/except to prevent 500 errors from bad config - Add i18n key integrations.connection_test_failed_fallback in en.json - Reference i18n key in template JS fallback message - Update SECURITY_AUDIT.md: add fix date (2026-03-23), update doc date - Remove accidental revert.sh file - Fix missing MagicMock/patch imports in test file - Add tests for invalid JSON config and tester exception error paths Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com> Agent-Logs-Url: https://github.com/christianlouis/DocuElevate/sessions/daebb70e-059a-4601-8864-88eef49f99cf
84 lines
2.6 KiB
YAML
84 lines
2.6 KiB
YAML
{{- /*
|
|
Celery Beat scheduler — publishes periodic tasks to the broker.
|
|
Exactly ONE replica must run; never scale this deployment.
|
|
*/ -}}
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: {{ include "docuelevate.fullname" . }}-beat
|
|
namespace: {{ .Release.Namespace }}
|
|
labels:
|
|
{{- include "docuelevate.labels" . | nindent 4 }}
|
|
app.kubernetes.io/component: beat
|
|
spec:
|
|
replicas: 1
|
|
strategy:
|
|
type: Recreate # Prevent two Beat instances from running simultaneously
|
|
selector:
|
|
matchLabels:
|
|
{{- include "docuelevate.selectorLabels" . | nindent 6 }}
|
|
app.kubernetes.io/component: beat
|
|
template:
|
|
metadata:
|
|
labels:
|
|
{{- include "docuelevate.selectorLabels" . | nindent 8 }}
|
|
app.kubernetes.io/component: beat
|
|
{{- with .Values.beat.podAnnotations }}
|
|
annotations:
|
|
{{- toYaml . | nindent 8 }}
|
|
{{- end }}
|
|
spec:
|
|
serviceAccountName: {{ include "docuelevate.serviceAccountName" . }}
|
|
{{- with .Values.imagePullSecrets }}
|
|
imagePullSecrets:
|
|
{{- toYaml . | nindent 8 }}
|
|
{{- end }}
|
|
{{- with .Values.beat.podSecurityContext }}
|
|
securityContext:
|
|
{{- toYaml . | nindent 8 }}
|
|
{{- end }}
|
|
containers:
|
|
- name: beat
|
|
image: {{ include "docuelevate.image" . }}
|
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
|
command:
|
|
- celery
|
|
- -A
|
|
- app.celery_worker
|
|
- beat
|
|
- --loglevel=info
|
|
envFrom:
|
|
- configMapRef:
|
|
name: {{ include "docuelevate.fullname" . }}-config
|
|
- secretRef:
|
|
name: {{ include "docuelevate.fullname" . }}-secret
|
|
{{- with .Values.beat.securityContext }}
|
|
securityContext:
|
|
{{- toYaml . | nindent 12 }}
|
|
{{- end }}
|
|
resources:
|
|
{{- toYaml .Values.beat.resources | nindent 12 }}
|
|
volumeMounts:
|
|
- name: workdir
|
|
mountPath: /workdir
|
|
volumes:
|
|
- name: workdir
|
|
{{- if .Values.workdir.persistence.enabled }}
|
|
persistentVolumeClaim:
|
|
claimName: {{ .Values.workdir.persistence.existingClaim | default (printf "%s-workdir" (include "docuelevate.fullname" .)) }}
|
|
{{- else }}
|
|
emptyDir: {}
|
|
{{- end }}
|
|
{{- with .Values.beat.nodeSelector }}
|
|
nodeSelector:
|
|
{{- toYaml . | nindent 8 }}
|
|
{{- end }}
|
|
{{- with .Values.beat.affinity }}
|
|
affinity:
|
|
{{- toYaml . | nindent 8 }}
|
|
{{- end }}
|
|
{{- with .Values.beat.tolerations }}
|
|
tolerations:
|
|
{{- toYaml . | nindent 8 }}
|
|
{{- end }}
|