CSIT-748 Add K8S 2memif-2vnf topologies
[csit.git] / resources / templates / kubernetes / eth-l2bdbase-eth-2memif-2vnf.yaml
1 ---
2 apiVersion: v1
3 kind: ConfigMap
4 metadata:
5   name: sfc-controller-cfg
6   namespace: csit
7 data:
8   etcd.conf:
9     insecure-transport: true
10     dial-timeout: 1000000000
11     endpoints:
12       - "172.17.0.1:22379"
13
14   sfc.conf:
15     sfc_controller_config_version: 1
16     description: $$TEST_NAME$$
17     host_entities:
18       - name: vswitch
19     sfc_entities:
20       - name: vswitch-vnf1
21         description: vswitch to VNF1 - memif
22         type: 3
23         elements:
24           - container: vswitch
25             port_label: $$VSWITCH_IF1$$
26             etcd_vpp_switch_key: vswitch
27             type: 5
28           - container: vnf1
29             port_label: port1
30             etcd_vpp_switch_key: vswitch
31             type: 2
32       - name: vswitch-vnf2
33         description: VNF2 to vswitch - memif
34         type: 3
35         elements:
36           - container: vswitch
37             port_label: $$VSWITCH_IF2$$
38             etcd_vpp_switch_key: vswitch
39             type: 5
40           - container: vnf2
41             port_label: port2
42             etcd_vpp_switch_key: vswitch
43             type: 2
44       - name: vnf1-vnf2
45         description: vnf1 to vnf2 via vswitch - memifs
46         type: 2
47         elements:
48           - container: vnf1
49             port_label: port2
50             etcd_vpp_switch_key: vswitch
51             type: 2
52           - container: vnf2
53             port_label: port1
54             etcd_vpp_switch_key: vswitch
55             type: 2
56
57   vnf.conf:
58     vnf_plugin_config_version: 1
59     description: VNF config
60     vnf_entities:
61       - name: vnf1
62         container: vnf1
63         l2xconnects:
64           - port_labels:
65             - port1
66             - port2
67       - name: vnf2
68         container: vnf2
69         l2xconnects:
70           - port_labels:
71             - port1
72             - port2
73
74 ---
75 apiVersion: v1
76 kind: Pod
77 metadata:
78   name: sfc-controller
79   namespace: csit
80 spec:
81   containers:
82     - name: "sfc-controller"
83       image: prod_sfc_controller
84       imagePullPolicy: IfNotPresent
85       command:
86         - /bin/sfc-controller
87         - -etcdv3-config=/opt/sfc-controller/dev/etcd.conf
88         - -sfc-config=/opt/sfc-controller/dev/sfc.conf
89         - -vnf-config=/opt/sfc-controller/dev/vnf.conf
90       volumeMounts:
91         - name: controller-config
92           mountPath: /opt/sfc-controller/dev
93   volumes:
94     - name: controller-config
95       configMap:
96         name: sfc-controller-cfg
97 ---
98 apiVersion: v1
99 kind: ConfigMap
100 metadata:
101   name: vswitch-agent-cfg
102   namespace: csit
103 data:
104   etcd.conf:
105     insecure-transport: true
106     dial-timeout: 1000000000
107     endpoints:
108       - "172.17.0.1:22379"
109
110   kafka.conf:
111     addrs:
112       - "172.17.0.1:9092"
113
114 ---
115 apiVersion: v1
116 kind: Pod
117 metadata:
118   name: vswitch-vpp
119   namespace: csit
120 spec:
121   hostNetwork: true
122   containers:
123     - name: "vswitch"
124       image: prod_vpp_agent_shrink
125       imagePullPolicy: IfNotPresent
126       securityContext:
127         privileged: true
128       ports:
129         - containerPort: 5002
130         - containerPort: 9191
131       readinessProbe:
132         httpGet:
133           path: /readiness
134           port: 9191
135         periodSeconds: 1
136       livenessProbe:
137         httpGet:
138           path: /liveness
139           port: 9191
140         periodSeconds: 1
141         initialDelaySeconds: 15
142       env:
143         - name: MICROSERVICE_LABEL
144           value: vswitch
145       volumeMounts:
146         - name: vpp-config
147           mountPath: /etc/vpp
148         - name: agent-config
149           mountPath: /opt/vpp-agent/dev
150         - name: memif-sockets
151           mountPath: /tmp
152   volumes:
153     - name: vpp-config
154       configMap:
155         name: vswitch-vpp-cfg
156     - name: agent-config
157       configMap:
158         name: vswitch-agent-cfg
159     - name: memif-sockets
160       hostPath:
161         path: /tmp
162 ---
163 apiVersion: v1
164 kind: ConfigMap
165 metadata:
166   name: vnf-agent-cfg
167   namespace: csit
168 data:
169   etcd.conf:
170     insecure-transport: true
171     dial-timeout: 1000000000
172     endpoints:
173       - "172.17.0.1:22379"
174
175   kafka.conf:
176     addrs:
177       - "172.17.0.1:9092"
178
179 ---
180 apiVersion: v1
181 kind: Pod
182 metadata:
183   name: vnf1-vpp
184   namespace: csit
185 spec:
186   containers:
187     - name: "vnf1"
188       image: prod_vpp_agent_shrink
189       imagePullPolicy: IfNotPresent
190       securityContext:
191         privileged: true
192       ports:
193         - containerPort: 5002
194         - containerPort: 9191
195       readinessProbe:
196         httpGet:
197           path: /readiness
198           port: 9191
199         periodSeconds: 1
200       livenessProbe:
201         httpGet:
202           path: /liveness
203           port: 9191
204         initialDelaySeconds: 15
205       env:
206         - name: MICROSERVICE_LABEL
207           value: vnf1
208       volumeMounts:
209         - name: vpp-config
210           mountPath: /etc/vpp
211         - name: agent-config
212           mountPath: /opt/vpp-agent/dev
213         - name: memif-sockets
214           mountPath: /tmp
215   volumes:
216   - name: vpp-config
217     configMap:
218       name: vnf1-vpp-cfg
219   - name: agent-config
220     configMap:
221       name: vnf-agent-cfg
222   - name: memif-sockets
223     hostPath:
224       path: /tmp
225
226 ---
227 apiVersion: v1
228 kind: Pod
229 metadata:
230   name: vnf2-vpp
231   namespace: csit
232 spec:
233   containers:
234     - name: "vnf2"
235       image: prod_vpp_agent_shrink
236       imagePullPolicy: IfNotPresent
237       securityContext:
238         privileged: true
239       ports:
240         - containerPort: 5002
241         - containerPort: 9191
242       readinessProbe:
243         httpGet:
244           path: /readiness
245           port: 9191
246         periodSeconds: 1
247       livenessProbe:
248         httpGet:
249           path: /liveness
250           port: 9191
251         initialDelaySeconds: 15
252       env:
253         - name: MICROSERVICE_LABEL
254           value: vnf2
255       volumeMounts:
256         - name: vpp-config
257           mountPath: /etc/vpp
258         - name: agent-config
259           mountPath: /opt/vpp-agent/dev
260         - name: memif-sockets
261           mountPath: /tmp
262   volumes:
263   - name: vpp-config
264     configMap:
265       name: vnf2-vpp-cfg
266   - name: agent-config
267     configMap:
268       name: vnf-agent-cfg
269   - name: memif-sockets
270     hostPath:
271       path: /tmp

©2016 FD.io a Linux Foundation Collaborative Project. All Rights Reserved.
Linux Foundation is a registered trademark of The Linux Foundation. Linux is a registered trademark of Linus Torvalds.
Please see our privacy policy and terms of use.