-
Notifications
You must be signed in to change notification settings - Fork 166
[chore] add logic to update our tests k8s versions #1792
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
Conversation
03a7022
to
382c2dc
Compare
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.
Nice!
382c2dc
to
91ee5c4
Compare
6a99c36
to
6c53f1e
Compare
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.
Looks good! With all of my comments feel free to drop or clarify as you see fit. I'm generally trying to reduce regexes and string parsing logic as much as possible. I'd be happy to discuss any options here.
d9609d7
to
3e8e5ec
Compare
e36557b
to
d24da35
Compare
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.
Sorry about all of the nits, once the formatting tools are introduced to the repo it'll catch earlier on in the process.
f1ab9ef
to
0656790
Compare
New push:
|
Once this PR has been rebased on |
02938f3
to
f4c62f5
Compare
@crobert-1
This is very restrictive, not if we want to no lint it or change the G306 gosec config to
|
I'd say for now my preference is to just add a nolint comment. I generally prefer getting warnings up front on new changes to let us make an educated decision on a case by case basis. Happy to hear from others though 👍 |
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.
LGTM once CI is passing. Thanks for all of your work here @dloucasfx!
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.
LGTM. Can be merged once the minor comment is addressed
return false, nil | ||
} | ||
|
||
func decrementMinorMinorVersion(version string) (string, error) { |
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.
It's called the patch version in semver :)
func decrementMinorMinorVersion(version string) (string, error) { | |
func decrementPatchVersion(version string) (string, error) { |
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.
roger that!
Signed-off-by: Dani Louca <[email protected]>
Signed-off-by: Dani Louca <[email protected]>
@dloucasfx We have some tests which use the K8S_VERSION var to look up for expected test data since the metrics change with k8s version for some receiver. These tests (i can only remember histograms from the top of my head) will probably start failing once a new minor version is introduced by this workflow. I took a look at the code and don't see this being addressed. Is this known? we can fix the tests once the new version is added or we could probably just copy the data from |
Description:
Added a utility to get a list of supported vanilla k8s clusters, compare it to our test k8s versions and update when necessary.
I added a make target, which we can keep or remove, but the end goal is to add a gh action that uses this logic to create a PR with the changes if detected.
We currently have a bunch of EOL k8s versions that we use, it's a way to check compatibility with cloud providers that extend the support.
This is not ideal as we keep increasing our test matrix and the vanilla cluster is not identical to the one used by the cloud provider. To test for schema compatibility, we should start using
kubeconform
To Do (sperate PRs):
Testing:
unit test