apiVersion: batch/v1
kind: Job
metadata:
  name: performance-test
  namespace: observability
spec:
  ttlSecondsAfterFinished: 3600
  backoffLimit: 0
  template:
    metadata:
      labels:
        app: performance-test
    spec:
      restartPolicy: Never
      containers:
      - name: performance-test
        image: <IMAGE_PLACEHOLDER>
        imagePullPolicy: Always
        args:
        - -test.v
        - -test.timeout=0
        - -test.run=TestWritePerformance|TestNormalReadPerformance
        env:
        - name: KUBECONFIG
          value: ""
        resources:
          requests:
            memory: "512Mi"
            cpu: "500m"
          limits:
            memory: "4Gi"
            cpu: "2000m"
        volumeMounts:
        - name: config
          mountPath: /app/perf_config.yaml
          subPath: perf_config.yaml
        - name: logs
          mountPath: /app/log
      volumes:
      - name: config
        configMap:
          name: performance-test-config
      - name: logs
        emptyDir: {}
