2026-01-13 04:27:16 +00:00
|
|
|
apiVersion: batch/v1
|
2026-02-03 01:56:09 +00:00
|
|
|
kind: CronJob
|
2026-01-13 04:27:16 +00:00
|
|
|
metadata:
|
2026-02-03 01:56:09 +00:00
|
|
|
name: analyst-gemma
|
|
|
|
|
namespace: customer1
|
2026-01-13 04:27:16 +00:00
|
|
|
spec:
|
2026-02-03 01:56:09 +00:00
|
|
|
schedule: "15 * * * *"
|
2026-01-13 04:27:16 +00:00
|
|
|
jobTemplate:
|
|
|
|
|
spec:
|
|
|
|
|
template:
|
2026-02-03 01:56:09 +00:00
|
|
|
spec:
|
2026-01-16 20:33:37 +00:00
|
|
|
volumes:
|
|
|
|
|
- name: ollama-storage
|
2026-02-04 01:44:28 +00:00
|
|
|
persistentVolumeClaim:
|
|
|
|
|
claimName: ollama-storage
|
|
|
|
|
|
2026-01-16 20:33:37 +00:00
|
|
|
|
|
|
|
|
initContainers:
|
|
|
|
|
- name: model-puller
|
|
|
|
|
image: ollama/ollama:latest
|
|
|
|
|
volumeMounts:
|
2026-02-03 01:56:09 +00:00
|
|
|
- name: ollama-storage
|
2026-01-16 20:33:37 +00:00
|
|
|
mountPath: /root/.ollama
|
|
|
|
|
command: ["/bin/sh", "-c"]
|
2026-02-10 04:16:40 +00:00
|
|
|
args: ["ollama serve & sleep 5 && ollama pull qwen2.5:14b-instruct"]
|
2026-01-13 04:27:16 +00:00
|
|
|
|
2026-02-03 01:56:09 +00:00
|
|
|
|
|
|
|
|
- name: ollama-sidecar
|
|
|
|
|
image: ollama/ollama:latest
|
|
|
|
|
restartPolicy: Always # This is the magic
|
2026-02-03 15:05:21 +00:00
|
|
|
env:
|
|
|
|
|
- name: OLLAMA_DEBUG
|
|
|
|
|
value: "2"
|
|
|
|
|
- name: OLLAMA_LOG_LEVEL
|
|
|
|
|
value: "DEBUG"
|
2026-02-03 01:56:09 +00:00
|
|
|
ports:
|
|
|
|
|
- containerPort: 11434
|
|
|
|
|
volumeMounts:
|
|
|
|
|
- name: ollama-storage
|
|
|
|
|
mountPath: /root/.ollama
|
|
|
|
|
resources:
|
|
|
|
|
limits:
|
|
|
|
|
nvidia.com/gpu: 1
|
2026-01-16 20:33:37 +00:00
|
|
|
containers:
|
2026-02-03 01:56:09 +00:00
|
|
|
- name: analyst
|
2026-02-10 03:14:56 +00:00
|
|
|
image: siriussec/summarizerlocal:2.6
|
2026-02-03 15:05:21 +00:00
|
|
|
imagePullPolicy: Always
|
2026-02-03 01:56:09 +00:00
|
|
|
env:
|
|
|
|
|
- name: DB_PASSWORD
|
|
|
|
|
valueFrom:
|
|
|
|
|
secretKeyRef:
|
|
|
|
|
name: news-user-password
|
|
|
|
|
key: password
|
|
|
|
|
envFrom:
|
|
|
|
|
- configMapRef:
|
2026-02-03 15:05:21 +00:00
|
|
|
name: gemma-config
|
2026-02-03 01:56:09 +00:00
|
|
|
# Make sure your summarizer script talks to http://localhost:11434
|
|
|
|
|
# (or http://127.0.0.1:11434)
|
|
|
|
|
|
|
|
|
|
restartPolicy: OnFailure
|
2026-02-04 01:44:28 +00:00
|
|
|
|
|
|
|
|
|