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: Service return an error when httpsPort set to null #209

Open
erwan-b opened this issue Feb 3, 2025 · 1 comment
Open

Bug: Service return an error when httpsPort set to null #209

erwan-b opened this issue Feb 3, 2025 · 1 comment

Comments

@erwan-b
Copy link
Contributor

erwan-b commented Feb 3, 2025

By default the Ingress use the https port to interact with the service. Becose the value httpsPort is set by default to 443.
And if we want to disable it, with a null, to force the Ingress to use httpPort we got this error:

Error: UPGRADE FAILED: cannot patch "flipt" with kind Service: Service "flipt" is invalid: spec.ports[1].port: Invalid value: 0: must be between 1 and 65535, inclusive

The service allways configure https port, so if set to null this create an error.

link to the chat on the PR #197

@erwan-b
Copy link
Contributor Author

erwan-b commented Feb 3, 2025

I see 2 simple way to avoid this error:

If condition in the service file, to avoid the error:

      {{- if .Values.service.httpsPort }}
     - port: {{ .Values.service.httpsPort }}
       targetPort: https
       protocol: TCP
       name: https
      {{- end}}

Service port in the value.yaml + new definition of the svcPort in the ingress file.

ingress:
  servicePort: 443

+

{{- $svcPort := .Values.ingress.servicePort -}}

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

No branches or pull requests

1 participant