feat: implement service type NodePort #2986
Open
+753 −34
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
This PR adds support for Kubernetes services of type
NodePort.I tried my best to keep the structure of the configuration and code the same as for the LoadBalancer service type.
If the configuration for the NodePort is enabled the LoadBalancer configuration is overwritten.
Specific ports to be used on the kubernetes node(s) can be specified, if left empty kubernetes picks a port based on the clusters configuration: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport
Implements #983
Probably supersedes #994
Since this is my first PR at Zalando and this repository, please feel free to let me know if you would like me to make changes, if you want a specific test or if I need to bump a version somewhere. Thank you!