hugoprudente / charts

FoundryVTT from 0.6 to 12.x
https://hugoprudente.github.io
Apache License 2.0
24 stars 17 forks source link

No support for NodePort service configuration #39

Open otisaardvark opened 2 years ago

otisaardvark commented 2 years ago

The service.yaml template does not support a NodePort service configuration

The following code added to the template after spec: would enable this service configuration

...
{{- if eq .Values.service.serviceType "NodePort" }}
  type: NodePort
  ports:
    - port: {{ .Values.service.port }}
      name: http
      targetPort: {{ .Values.service.port }}
      nodePort: {{ .Values.service.nodePort }}
      protocol:  {{ .Values.service.protocol }}
{{- else if (or (eq .Values.service.serviceType "ClusterIP") (empty .Values.service.serviceType)) }}
...

To use use this configuration, the values.yaml would need to contain a definition similar to the following: -

service:
  serviceType: NodePort
  port: 30000
  nodePort: 30000
  protocol: TCP
  labels: {}
  annotations: {}
hugoprudente commented 2 years ago

Nice! @otisaardvark !

I'll work on that one. I'm generally behind load balancers so didn't cross my mind support a simple NodePort. Cheers!