Skip to content

Instantly share code, notes, and snippets.

@wbuchwalter
Last active April 11, 2018 16:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wbuchwalter/bf59359e92f83e0580db8b80988eec81 to your computer and use it in GitHub Desktop.
Save wbuchwalter/bf59359e92f83e0580db8b80988eec81 to your computer and use it in GitHub Desktop.
apiVersion: batch/v1
kind: Job
metadata:
name: nvidia-smi
spec:
template:
metadata:
name: nvidia-smi
spec:
restartPolicy: Never
containers:
- image: nvidia/cuda
name: nvidia-smi
args:
- nvidia-smi
resources:
limits:
alpha.kubernetes.io/nvidia-gpu: 1
requests:
alpha.kubernetes.io/nvidia-gpu: 1
volumeMounts:
- mountPath: /usr/bin/
name: binaries
- mountPath: /usr/lib/x86_64-linux-gnu
name: libraries
volumes:
- name: binaries
hostPath:
path: /usr/bin/
- name: libraries
hostPath:
path: /usr/lib/x86_64-linux-gnu
@sshepel
Copy link

sshepel commented Apr 11, 2018

@wbuchwalter IMHO hostPath and mountPath needs to be updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment