Skip to content
Snippets Groups Projects
Commit 64e9135e authored by Björn Vonheiden's avatar Björn Vonheiden Committed by Sören Henning
Browse files

Enable volumes in the theodolite script

Add persistenVolume and persistentVolumeClaim to have a persistent
storage for the resulst of the theodolite job.
parent 39590ea0
Branches
Tags
1 merge request!57Use a Kubernetes volume to store results if executed as Kubernetes job
apiVersion: v1
kind: PersistentVolume
metadata:
name: theodolite-pv-volume
labels:
type: local
spec:
storageClassName: theodolite
capacity:
storage: 100m
accessModes:
- ReadWriteOnce
hostPath:
path: "</your/path/to/results/folder>"
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: theodolite-pv-claim
spec:
storageClassName: theodolite
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 100m
...@@ -5,6 +5,10 @@ metadata: ...@@ -5,6 +5,10 @@ metadata:
spec: spec:
template: template:
spec: spec:
volumes:
- name: theodolite-pv-storage
persistentVolumeClaim:
claimName: theodolite-pv-claim
containers: containers:
- name: theodolite - name: theodolite
image: bvonheid/theodolite:latest image: bvonheid/theodolite:latest
...@@ -32,8 +36,13 @@ spec: ...@@ -32,8 +36,13 @@ spec:
value: "http://prometheus-operated:9090" value: "http://prometheus-operated:9090"
# - name: NAMESPACE # - name: NAMESPACE
# value: "default" # value: "default"
- name: RESULT_PATH
value: "results"
- name: PYTHONUNBUFFERED - name: PYTHONUNBUFFERED
value: "1" value: "1"
volumeMounts:
- mountPath: "/app/results"
name: theodolite-pv-storage
restartPolicy: Never restartPolicy: Never
backoffLimit: 4 backoffLimit: 4
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment