-
Notifications
You must be signed in to change notification settings - Fork 10
/
multitenancy-inline.yml
70 lines (65 loc) · 2.03 KB
/
multitenancy-inline.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# Example HostProcess DaemonSets for the MCDM device plugin and the WDDM device plugin, using settings that enable multitenancy
#
# This version of the DaemonSets sets environment variable values directly in the Pod spec. For a version that uses a ConfigMap
# to provide configuration values, see the file `multitenancy-configmap.yml`
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: device-plugin-mcdm
spec:
selector:
matchLabels:
app: device-plugin-mcdm
template:
metadata:
labels:
app: device-plugin-mcdm
spec:
nodeSelector:
kubernetes.io/os: 'windows'
kubernetes.io/arch: 'amd64'
node.kubernetes.io/windows-build: '10.0.20348'
securityContext:
windowsOptions:
hostProcess: true
runAsUserName: "NT AUTHORITY\\SYSTEM"
hostNetwork: true
containers:
- name: device-plugin-mcdm
image: "index.docker.io/tensorworks/mcdm-device-plugin:0.0.1"
imagePullPolicy: Always
# Configure the MCDM device plugin to allow 4 containers to mount each compute-only device simultaneously
env:
- name: MCDM_DEVICE_PLUGIN_MULTITENANCY
value: "4"
---
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: device-plugin-wddm
spec:
selector:
matchLabels:
app: device-plugin-wddm
template:
metadata:
labels:
app: device-plugin-wddm
spec:
nodeSelector:
kubernetes.io/os: 'windows'
kubernetes.io/arch: 'amd64'
node.kubernetes.io/windows-build: '10.0.20348'
securityContext:
windowsOptions:
hostProcess: true
runAsUserName: "NT AUTHORITY\\SYSTEM"
hostNetwork: true
containers:
- name: device-plugin-wddm
image: "index.docker.io/tensorworks/wddm-device-plugin:0.0.1"
imagePullPolicy: Always
# Configure the WDDM device plugin to allow 4 containers to mount each display device simultaneously
env:
- name: WDDM_DEVICE_PLUGIN_MULTITENANCY
value: "4"