apiVersion: v1
kind: Pod
metadata:
  labels:
    app: gpu-burn
  name: gpu-burn-{{ gpu_node_name }}
  namespace: default
spec:
  restartPolicy: Never
  containers:
  - image: nvcr.io/nvidia/cuda:11.2.2-devel-ubi8
    imagePullPolicy: Always
    name: gpu-burn-ctr
    command:
    - /bin/entrypoint.sh
    volumeMounts:
    - name: entrypoint
      mountPath: /bin/entrypoint.sh
      readOnly: true
      subPath: entrypoint.sh
    env:
    - name: GPU_BURN_TIME
      value: "{{ gpu_burn_time }}"
  volumes:
    - name: entrypoint
      configMap:
        defaultMode: 0700
        name: gpu-burn-entrypoint
  nodeSelector:
    nvidia.com/gpu.present: "true"
    kubernetes.io/hostname: "{{ gpu_node_hostname }}"
