-
Notifications
You must be signed in to change notification settings - Fork 459
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Match pod dnsPolicy
to hostNetwork
config
#691
Match pod dnsPolicy
to hostNetwork
config
#691
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add test to validate this.
) | ||
|
||
func getDnsPolicy(otelcol v1alpha1.OpenTelemetryCollector) corev1.DNSPolicy { | ||
dnsPolicy := corev1.DNSClusterFirst |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this be rather "Default" ?
https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-s-dns-policy
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Found this section on that page:
Note: "Default" is not the default DNS policy. If dnsPolicy is not explicitly specified, then "ClusterFirst" is used.
Actually I don't know if |
@gai6948 the CI failed |
This is why we should understand why people want to use |
My use case for |
@gai6948 the CI is still failing? Please fix it to move this forward. |
@gai6948 FYI, the host network tests are failing for details on tests, here are refs |
The tests should pass now |
* feat: match pod dnspolicy to hostNetwork * feat: add dnspolicy support to deployment and sts * added tests for hostNetwork DNSpolicy * use hostnetwork spec in deployment and statefulset
Resolves #690
I added a simple check to make the pods' DNSPolicy matching the
hostNetwork
option