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

Adds serverPort for webhook in helm chart, and adds the same option for metricsPort and healthProbePort #4212

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

mbentancour
Copy link

Adds serverPort for webhook in helm chart, and adds the same option for metricsPort and healthProbePort

For setups using EKS with a third-party CNI (e.g. Cilium) in overlay mode, the webhook needs to run with hostNetwork: true.
This presents a potential issue with conflicting ports. #2624 addressed this on the webhook itself, but did not add the option for the helm chart. This PR adds this setting to the helm chart, and expands the functionality by allowing to set healthProbePort and metricsPort.

The code changes are:

  • Add environment variables to the deployment in helm
  • Modify the webhook manager.go code to use the environment variables for metricsPort and healthProbePort if provided (same as was done in Add WEBHOOK_PORT environment variable #2624 for serverPort)
  • Modify tests to include all custom ports
  • Modify values file to include the new settings

These are the steps to validate the PR:

  • Create an EKS cluster with Cilium running on overlay mode
  • Create a deployment using hostNetwork and open one of the ports used by the webhook and a number of replicas of at least equals to the number of nodes
  • Deploy the dynatrace-operator helm chart with default ports
  • Check that the dynatrace-webhook is pending due to unavailable ports
  • Specify new, non-conflicting ports for the webhook
  • Check that the pods now start as expected

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.

1 participant