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

[BUG] Kubernetes service uses http instead of https, causing Istio conflicts #958

Open
tombojer opened this issue Feb 17, 2025 · 0 comments
Labels
bug Something isn't working untriaged Issues that have not yet been triaged

Comments

@tombojer
Copy link

What is the bug?

The port name in the service definition is set to http even though the application listens for https. This misconfiguration may lead to issues with protocol selection in service meshes like Istio.

How can one reproduce the bug?

  1. Deploy the OpenSearch Kubernetes Operator and an Opensearch cluster in an istio enabled namespace.
  2. Inspect the generated service definition.
  3. Observe that the port is named http, while the application actually exposes https.
  4. Curl the cluster

What is the expected behavior?

The service definition should correctly reflect that the application is using https by naming the port accordingly.

What is your host/environment?

  • Kubernetes Version: 1.31
  • OpenSearch Kubernetes Operator Version: 2.7.0
  • Cloud Provider or Platform: EKS

Do you have any screenshots?

Not applicable, but YAML snippets are provided below.

Do you have any additional context?

The current service definition incorrectly labels the port as http:

ports:
  - name: http
    port: 9200
    protocol: TCP
    targetPort: 9200

It should instead be:

ports:
  - name: https
    port: 9200
    protocol: TCP
    targetPort: 9200

Alternatively, setting the appProtocol field could also resolve the issue, as discussed in Issue #751.

For reference, the Istio documentation on protocol selection explains why proper naming is crucial for service discovery and traffic routing.

@tombojer tombojer added bug Something isn't working untriaged Issues that have not yet been triaged labels Feb 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working untriaged Issues that have not yet been triaged
Projects
Status: 🆕 New
Development

No branches or pull requests

1 participant