-
Notifications
You must be signed in to change notification settings - Fork 23
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
Upgrade/kubernetes v1.22 #171
Upgrade/kubernetes v1.22 #171
Conversation
{{- if .Capabilities.APIVersions.Has "networking.k8s.io/v1" }} | ||
apiVersion: networking.k8s.io/v1 | ||
{{- else if .Capabilities.APIVersions.Has "networking.k8s.io/v1beta" -}} | ||
apiVersion: networking.k8s.io/v1beta | ||
{{- else -}} | ||
apiVersion: extensions/v1beta1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
was this removed in v1.14? when should we remove this from the chart definition? :)
I'm just keeping it as a defense mechanism but would love to learn of what our thoughts are regarding this.
Anything I can do to expedite this and finish up this pull request so it can be merged into Porter? |
I could have another look and just clean it up a bit. There are other templates in the repo that needs updating as I mentioned in my original comment |
No worries! :) |
Hey @nikokon - so very sorry I haven't been able to get around to reviewing this. I'll be sure to take care of it either today or early tomorrow. Thanks ever so much! |
ping @rudimk :) |
Hey @nikokon - sitting on this today, the aim is to spin up a couple of testbed clusters running K8s v1.22 and test your changes out. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @nikokon, thanks again for this PR, and apologies for the delay. We've been extremely busy with version deprecations on various cloud providers, so it's been hard to prioritize 1.22 until now. That said, we are targeting full support on 1.22 across all addons in the next couple weeks, starting with the web
chart.
I've added a code review, please let me know if there are any questions :)
To answer your query:
When do we allow breaking changes? when do we stop supporting kubernetes EOL versions etc? 🤷
I think in our case we will remove support for the old extensions/v1beta1
once 1.21 has officially been deprecated by the major providers (EKS, GKE, DOKS). This is a much longer timeline than the Kubernetes deprecation schedule but our primary concern is supporting users on the cloud providers, who might not upgrade their clusters until the last minute.
Co-authored-by: abelanger5 <alexander.b138@gmail.com>
Co-authored-by: abelanger5 <alexander.b138@gmail.com>
Co-authored-by: abelanger5 <alexander.b138@gmail.com>
Co-authored-by: abelanger5 <alexander.b138@gmail.com>
hey @abelanger5 I applied your suggestions from the code review. took a while before I realized I could do it in bulk 🥲 Feel free to merge if all looks good! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @nikokon, I've added a few more code review comments after testing on various clusters.
servicePort: {{ .servicePort }} | ||
{{- end }} | ||
{{- end }} | ||
{{ else }} | ||
- backend: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- backend: |
I think this lingering backend:
block is throwing things off. Here's the block that worked for me:
- {{- if $.Capabilities.APIVersions.Has "networking.k8s.io/v1/Ingress" }}
pathType: ImplementationSpecific
{{- end }}
backend:
{{- if $.Capabilities.APIVersions.Has "networking.k8s.io/v1/Ingress" }}
service:
name: {{ $fullName }}
port:
number: {{ $svcPort }}
{{- else }}
serviceName: {{ $fullName }}
servicePort: {{ $svcPort }}
{{- end }}
Additionally -- upgrades once a user is on
Even though GKE will support the deprecated According to the Helm docs (https://helm.sh/docs/topics/kubernetes_apis/#helm-users), we will need to patch an existing Helm release with the new API versions before the user can upgrade. As a result, we cannot merge this in until we're able to perform this patch from the Porter server. Hopefully this won't take too long to get added. |
Co-authored-by: abelanger5 <alexander.b138@gmail.com>
@abelanger5 |
Was setting up dev environment in order to get cracking on implementing some features when I noticed I was having trouble deploying a new app with ingress in my local minikube cluster.
Some of the beta-apis have been deprecated in kubernetes v1.22 and started following this "guide".
https://kubernetes.io/blog/2021/07/14/upcoming-changes-in-kubernetes-1-22/
I think there are some more charts that need updating. mongodb, porteragent, prometheus for example use the "authorization.k8s.io/v1beta1"
While this PR does not adress those, I wanted to submit it as I'm not that experienced in best practices etc when it comes to versioning and deprecations using helm.
When do we allow breaking changes? when do we stop supporting kubernetes EOL versions etc? 🤷