File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -597,8 +597,14 @@ func (r *driverReconcile) reconcileControllerPluginDeployment() error {
597597 ServiceAccountName : serviceAccountName ,
598598 PriorityClassName : ptr .Deref (pluginSpec .PrioritylClassName , "" ),
599599 HostNetwork : ptr .Deref (pluginSpec .HostNetwork , false ),
600- Affinity : getControllerPluginPodAffinity (pluginSpec , & appSelector ),
601- Tolerations : pluginSpec .Tolerations ,
600+ DNSPolicy : utils .Call (func () corev1.DNSPolicy {
601+ if ptr .Deref (pluginSpec .HostNetwork , false ) {
602+ return corev1 .DNSClusterFirstWithHostNet
603+ }
604+ return corev1 .DNSClusterFirst
605+ }),
606+ Affinity : getControllerPluginPodAffinity (pluginSpec , & appSelector ),
607+ Tolerations : pluginSpec .Tolerations ,
602608 Containers : utils .Call (func () []corev1.Container {
603609 containers := []corev1.Container {
604610 // Plugin Container
You can’t perform that action at this time.
0 commit comments