Skip to content
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

fix: external-dns does not work when adding ip for my pihole #2

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Chever-John
Copy link

@Chever-John Chever-John commented Sep 1, 2024

Just as the title says, this PR solves this issue.

Just add a nginx annotation rule.

Closes #3

@dueyfinster
Copy link

@Chever-John I feel my PR is simpler to understand for a newbie since he showed example of it in video already. I'm no K8S expert by a long way but yours appears more technically correct to me?

@Chever-John
Copy link
Author

@dueyfinster

TLDR: I agree with you:)

ingress:
  enabled: true
  hosts:
    - "pihole.home"
  annotations:
    kubernetes.io/ingress.class: "nginx-internal"

Advantages

Flexibility: By specifyingingress.class using annotations, it is easy to switch between different Ingress Controllers without modifying Ingress resources. this is useful for scenarios where you need to use different Ingress Controllers in different environments.

Compatibility: Many existing tools and plugins support configuring Ingress via annotations, which makes this approach more compatible in some cases.

Disadvantages

Readability: The use of annotations may result in less readable configuration files, especially if there are more annotations.

Standardization: The use of annotations may lead to inconsistency in configuration, especially in teamwork where different developers may use different annotations to implement the same functionality.

ingress:
  ingressClassName: nginx-internal
  enabled: true
  hosts:
    - "pihole.home"

Advantages

Simplicity: Using the ingressClassName field directly to specify the Ingress Controller, the configuration is more concise and clear, easy to understand and maintain.

Consistency: By using Kubernetes native fields, it ensures consistency and standardization of the configuration and reduces configuration inconsistencies caused by different annotations.

Disadvantages

Flexibility: Compared to the approach of using annotations, using ingressClassName directly may not be flexible enough in some cases, especially if you need to switch Ingress Controllers dynamically.

Support: some older versions of Kubernetes or specific tools may not support the ingressClassName field.

@dueyfinster
Copy link

Thanks for the explanation - every day is a school day as they say 😄

@Chever-John
Copy link
Author

@dueyfinster Learning never stops! 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug: external dns does not work when i tried to use it add my pihole's ip resolv
2 participants