add sriov in docker stack

This commit is contained in:
Your Name
2024-07-03 04:30:24 +00:00
parent ef91582d78
commit ec4d6f45c7

View File

@@ -48,12 +48,14 @@ services:
- discrete_resource_spec: - discrete_resource_spec:
kind: "NVIDIA-GPU" kind: "NVIDIA-GPU"
value: 8 value: 8
- discrete_resource_spec:
kind: "SRIOV-VF"
value: 1
placement: placement:
constraints: [node.labels.gpu == true] constraints: [node.labels.gpu == true]
cap_add: cap_add:
- IPC_LOCK - IPC_LOCK
devices: privileged: true
- "/dev/infiniband:/dev/infiniband:rwm"
networks: networks:
my-custom-bridge: my-custom-bridge: