[OVS] Add .Values.openvswitch.extraContainers hook
This is aligned with the Helm best practices when users can inject optional snippets into template. E.g exporter sidecar suits this use case. Change-Id: I5e0f7784f740a16314382d63717f1b749ef7903a Signed-off-by: Vladimir Kozhukalov <kozhukalov@gmail.com>
This commit is contained in:
@@ -223,6 +223,9 @@ It should be handled through lcore and pmd core masks. */}}
|
||||
- name: var-tmp
|
||||
mountPath: /var/tmp
|
||||
{{- end }}
|
||||
{{- with .Values.openvswitch.extraContainers }}
|
||||
{{- tpl (toYaml .) $envAll | nindent 8 }}
|
||||
{{- end }}
|
||||
volumes:
|
||||
- name: pod-tmp
|
||||
emptyDir: {}
|
||||
|
||||
@@ -104,6 +104,7 @@ pod:
|
||||
- NET_ADMIN
|
||||
readOnlyRootFilesystem: true
|
||||
dns_policy: "ClusterFirstWithHostNet"
|
||||
|
||||
lifecycle:
|
||||
upgrades:
|
||||
daemonsets:
|
||||
@@ -209,6 +210,9 @@ manifests:
|
||||
network_policy: false
|
||||
secret_registry: true
|
||||
|
||||
openvswitch:
|
||||
extraContainers: []
|
||||
|
||||
conf:
|
||||
poststart:
|
||||
timeout: 5
|
||||
|
||||
7
releasenotes/notes/openvswitch-3401ba2f0dc8e1f6.yaml
Normal file
7
releasenotes/notes/openvswitch-3401ba2f0dc8e1f6.yaml
Normal file
@@ -0,0 +1,7 @@
|
||||
---
|
||||
openvswitch:
|
||||
- |
|
||||
Introduce .Values.openvswitch.extraContainers hook to make it possible to
|
||||
add extra containers to openvswitch daemonset, e.g. for monitoring
|
||||
purposes.
|
||||
...
|
||||
38
values_overrides/openvswitch/exporter.yaml
Normal file
38
values_overrides/openvswitch/exporter.yaml
Normal file
@@ -0,0 +1,38 @@
|
||||
---
|
||||
openvswitch:
|
||||
extraContainers:
|
||||
- name: ovs-exporter
|
||||
image: ghcr.io/saeed-mcu/ovs_exporter/openvswitch_exporter:v2.3.2
|
||||
imagePullPolicy: IfNotPresent
|
||||
ports:
|
||||
- name: metrics
|
||||
containerPort: 9475
|
||||
protocol: TCP
|
||||
livenessProbe:
|
||||
httpGet:
|
||||
path: /metrics
|
||||
port: 9475
|
||||
initialDelaySeconds: 30
|
||||
periodSeconds: 60
|
||||
timeoutSeconds: 5
|
||||
readinessProbe:
|
||||
httpGet:
|
||||
path: /metrics
|
||||
port: 9475
|
||||
initialDelaySeconds: 15
|
||||
periodSeconds: 30
|
||||
timeoutSeconds: 5
|
||||
securityContext:
|
||||
readOnlyRootFilesystem: true
|
||||
resources:
|
||||
requests:
|
||||
memory: "128Mi"
|
||||
cpu: "100m"
|
||||
limits:
|
||||
memory: "256Mi"
|
||||
cpu: "500m"
|
||||
volumeMounts:
|
||||
- name: run
|
||||
mountPath: /run
|
||||
readOnly: true
|
||||
...
|
||||
@@ -149,7 +149,9 @@
|
||||
- ./tools/deployment/component/keystone/keystone.sh
|
||||
- ./tools/deployment/component/heat/heat.sh
|
||||
- export GLANCE_BACKEND=local; ./tools/deployment/component/glance/glance.sh
|
||||
- ./tools/deployment/component/compute-kit/openvswitch.sh
|
||||
- >-
|
||||
export OSH_EXTRA_HELM_ARGS="--values ../openstack-helm/values_overrides/openvswitch/exporter.yaml";
|
||||
./tools/deployment/component/compute-kit/openvswitch.sh
|
||||
- >-
|
||||
export OSH_EXTRA_HELM_ARGS="--values ../openstack-helm/values_overrides/libvirt/inovex_exporter.yaml";
|
||||
./tools/deployment/component/compute-kit/libvirt.sh
|
||||
|
||||
Reference in New Issue
Block a user