-
Notifications
You must be signed in to change notification settings - Fork 17
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
Add ECK version to version.json #270
Comments
One thing to note: eck-diagnostics supports multiple operator namespaces, so there can be different operator versions in the same archive: > grep eck-operator- -r eck-diagnostics-2024-10-17T14-59-53 | grep serviceaccount
eck-diagnostics-2024-10-17T14-59-53/elastic-system/serviceaccount.json: "helm.sh/chart": "eck-operator-2.14.0"
eck-diagnostics-2024-10-17T14-59-53/elastic-system-11/serviceaccount.json: "helm.sh/chart": "eck-operator-2.11.0" We are currently printing the maximum version of all operator versions. eck-diagnostics/internal/diag.go Lines 132 to 133 in 63629aa
|
@thbkrkr , cheers! Sorry, my team's a tad confused on how to action your excellent clarification. As follow-up:
Will send you internal discussion link in DM. |
You have to look at the operator configuration specifically the
The only other potential benefit I can see is that it allows to debug misconfigurations where multiple operators are responsible for the same namespace. This is hard to figure our if you only pull the diagnostic for one operator out of many in a k8s cluster. |
We could either log all operator versions in this file, or the max operator version. {
"elastic-system/elastic-operator": {"version": "2.14.0", "managed_namespaces": ["ns1", "ns2"]},
"other-ns/elastic-operator": {"version": "2.13.0", "managed_namespaces": ["*"]},
} The above example would show a misconfiguration if we use |
@stefnestor maybe you could explain what the motivation for this change request is. Are you planning to build some tooling around this that requires the version information to be in a structured format or are you just trying to understand how to read the data in the archive? The reason I am asking is that there different levels of effort associated with the different ways to solve this, so it would be good to understand the use case better. |
Initially, it was going to be to write an analyzer, until @thbkrkr 's first response wiped out my assumptions 😂. So for now, I'm just interested in understanding so that I can flush out "how to read ECK diags" for my team. We usually only see 1 operator to 1 workload so can use which of the two reports But very quickly I'd be interesetd in building a diag analyzer on top so am interested in deriving the conversation via
So I don't mean at all to say there's a problem with current diag, other than apparent assumption ignorance my side, sorry 🙃. I think a gap I at least had that you highlighted well in DM helps this ballpark:
If I'm reading correctly, an operator restricted to namespaces would be via this doc. From your outline it sounds like that'd still reflect in the existing |
Not that's not it. It is this document which then translates to a configmap with the
Yes, if the value is not configured or set to "" it means all namespaces. See operator config doc:
|
Ah, this is more complicated than I thought 🙈. I would like to instead request your earlier idea of a |
👋 howdy, team (cc: @kunisen @jakommo 🙏!)
AFAICT, currently in order to determine the running ECK version, we have to regex search
ECK version is (.+?)\n
from undereck-diagnostics.log
which emits from this code:eck-diagnostics/internal/version.go
Lines 25 to 31 in f532395
Will you kindly consider expanding the
version.json
file to include this content, likely by extending this code:eck-diagnostics/internal/kubectl.go
Lines 453 to 482 in f532395
Example diagnostic of current state:
I was told after filing this ballpark also potentially comes through in a lower file; however, since the namespace can be dynamic requesting in a root-folder file:
The text was updated successfully, but these errors were encountered: