Skip to content

Commit 6bdcda1

Browse files
committed
deployment: add minimal kustomize overlays for deploying plugins
Signed-off-by: Markus Lehtonen <markus.lehtonen@intel.com>
1 parent 8c53e55 commit 6bdcda1

File tree

18 files changed

+422
-0
lines changed

18 files changed

+422
-0
lines changed
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
apiVersion: apps/v1
2+
kind: DaemonSet
3+
metadata:
4+
name: nri-plugin-device-injector
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- name: plugin
10+
image: plugin:latest
11+
imagePullPolicy: Always
12+
args:
13+
- "-idx"
14+
- "10"
15+
resources:
16+
requests:
17+
cpu: "2m"
18+
memory: "5Mi"
19+
volumeMounts:
20+
- name: nri-socket
21+
mountPath: /var/run/nri/nri.sock
22+
volumes:
23+
- name: nri-socket
24+
hostPath:
25+
path: /var/run/nri/nri.sock
26+
type: Socket
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
4+
namespace: kube-system
5+
6+
resources:
7+
- daemonset.yaml
8+
9+
images:
10+
- name: plugin
11+
newName: ghcr.io/containerd/nri/plugins/device-injector
12+
newTag: unstable
13+
14+
labels:
15+
- includeSelectors: true
16+
pairs:
17+
app: nri-plugin-device-injector
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
apiVersion: apps/v1
2+
kind: DaemonSet
3+
metadata:
4+
name: nri-plugin-differ
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- name: plugin
10+
image: plugin:latest
11+
imagePullPolicy: Always
12+
args: []
13+
resources:
14+
requests:
15+
cpu: "2m"
16+
memory: "5Mi"
17+
volumeMounts:
18+
- name: nri-socket
19+
mountPath: /var/run/nri/nri.sock
20+
volumes:
21+
- name: nri-socket
22+
hostPath:
23+
path: /var/run/nri/nri.sock
24+
type: Socket
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
4+
namespace: kube-system
5+
6+
resources:
7+
- daemonset.yaml
8+
9+
images:
10+
- name: plugin
11+
newName: ghcr.io/containerd/nri/plugins/differ
12+
newTag: unstable
13+
14+
labels:
15+
- includeSelectors: true
16+
pairs:
17+
app: nri-plugin-differ
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
apiVersion: apps/v1
2+
kind: DaemonSet
3+
metadata:
4+
name: nri-plugin-hook-injector
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- name: plugin
10+
image: plugin:latest
11+
imagePullPolicy: Always
12+
args:
13+
- "-idx"
14+
- "10"
15+
resources:
16+
requests:
17+
cpu: "2m"
18+
memory: "5Mi"
19+
volumeMounts:
20+
- name: nri-socket
21+
mountPath: /var/run/nri/nri.sock
22+
- name: etc-hooks-d
23+
mountPath: /etc/containers/oci/hooks.d
24+
readOnly: true
25+
- name: usr-share-hooks-d
26+
mountPath: /usr/share/containers/oci/hooks.d
27+
readOnly: true
28+
- name: libexec-hooks-d
29+
mountPath: /usr/libexec/oci/hooks.d
30+
readOnly: true
31+
volumes:
32+
- name: nri-socket
33+
hostPath:
34+
path: /var/run/nri/nri.sock
35+
type: Socket
36+
- name: etc-hooks-d
37+
hostPath:
38+
path: /etc/containers/oci/hooks.d
39+
type: DirectoryOrCreate
40+
- name: usr-share-hooks-d
41+
hostPath:
42+
path: /usr/share/containers/oci/hooks.d
43+
type: DirectoryOrCreate
44+
- name: libexec-hooks-d
45+
hostPath:
46+
path: /usr/libexec/oci/hooks.d
47+
type: DirectoryOrCreate
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
4+
namespace: kube-system
5+
6+
resources:
7+
- daemonset.yaml
8+
9+
images:
10+
- name: plugin
11+
newName: ghcr.io/containerd/nri/plugins/hook-injector
12+
newTag: unstable
13+
14+
labels:
15+
- includeSelectors: true
16+
pairs:
17+
app: nri-plugin-hook-injector
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
apiVersion: apps/v1
2+
kind: DaemonSet
3+
metadata:
4+
name: nri-plugin-logger
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- name: plugin
10+
image: plugin:latest
11+
imagePullPolicy: Always
12+
args:
13+
- "-idx"
14+
- "10"
15+
- "-events"
16+
- "RunPodSandbox,StopPodSandbox,RemovePodSandbox,CreateContainer,PostCreateContainer,StartContainer,PostStartContainer,UpdateContainer,PostUpdateContainer,StopContainer,RemoveContainer"
17+
resources:
18+
requests:
19+
cpu: "2m"
20+
memory: "5Mi"
21+
volumeMounts:
22+
- name: nri-socket
23+
mountPath: /var/run/nri/nri.sock
24+
volumes:
25+
- name: nri-socket
26+
hostPath:
27+
path: /var/run/nri/nri.sock
28+
type: Socket
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
4+
namespace: kube-system
5+
6+
resources:
7+
- daemonset.yaml
8+
9+
images:
10+
- name: plugin
11+
newName: ghcr.io/containerd/nri/plugins/logger
12+
newTag: unstable
13+
14+
labels:
15+
- includeSelectors: true
16+
pairs:
17+
app: nri-plugin-logger
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
apiVersion: apps/v1
2+
kind: DaemonSet
3+
metadata:
4+
name: nri-plugin-network-device-injector
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- name: plugin
10+
image: plugin:latest
11+
imagePullPolicy: Always
12+
args:
13+
- "-idx"
14+
- "10"
15+
resources:
16+
requests:
17+
cpu: "2m"
18+
memory: "5Mi"
19+
volumeMounts:
20+
- name: nri-socket
21+
mountPath: /var/run/nri/nri.sock
22+
volumes:
23+
- name: nri-socket
24+
hostPath:
25+
path: /var/run/nri/nri.sock
26+
type: Socket
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
apiVersion: kustomize.config.k8s.io/v1beta1
2+
kind: Kustomization
3+
4+
namespace: kube-system
5+
6+
resources:
7+
- daemonset.yaml
8+
9+
images:
10+
- name: plugin
11+
newName: ghcr.io/containerd/nri/plugins/network-device-injector
12+
newTag: unstable
13+
14+
labels:
15+
- includeSelectors: true
16+
pairs:
17+
app: nri-plugin-network-device-injector

0 commit comments

Comments
 (0)