Comments (4)
Thanks for reporting this 👍, I agree. Always assumed it's supported by default in the K8s go client, but seems like it is not.
from kube-no-trouble.
Support to KUBECONFIG env variable has been merged in #86. 🎉 There will be a new release hopefully soon in Jan, but if anyone wants to give it a go till then, it should be available in next nightly build which gets published in GH Releases.
from kube-no-trouble.
I have a KUBECONFIG
with several separate files in it.
The version I first installed was 0.2.0. I used this workaround successfully
kubent -k <(kubectl config view --flatten)
I then updated to 0.3.2 (the latest, I think, from 22 Sep 2020) but the above no longer works. It just gives
$ kubent -k <(kubectl config view --flatten)
INF >>> Kube No Trouble `kubent` <<<
INF version 0.3.2 (git sha 919129b596890475965cda2b972cb6fded71f40b)
INF Initializing collectors and retrieving data
ERR Failed to initialize collector: <nil> error="invalid configuration: no configuration has been provided"
ERR Failed to initialize collector: <nil> error="invalid configuration: no configuration has been provided"
INF Retrieved 13 resources from collector name=Cluster
INF Loaded ruleset name=deprecated-1-16.rego
INF Loaded ruleset name=deprecated-1-22.rego
Strangely, the below does produce output but it isn't the same as what 0.2.0 gives me.
kubectl config view --flatten > kubeconfig && kubent -k kubeconfig
Examples of differences - first, with 0.2.0
INF Retrieved 111 resources from collector name=Cluster
INF Retrieved 138 resources from collector name="Helm v3"
>>> 1.20 Deprecated APIs <<<
------------------------------------------------------------------------------------------
KIND NAMESPACE NAME API_VERSION
Ingress myns mying extensions/v1beta1
And with 0.3.2
INF Retrieved 13 resources from collector name=Cluster
INF Retrieved 0 resources from collector name="Helm v2"
INF Retrieved 138 resources from collector name="Helm v3"
>>> Deprecated APIs removed in 1.22 <<<
------------------------------------------------------------------------------------------
KIND NAMESPACE NAME API_VERSION
Ingress <undefined> mying extensions/v1beta1
Hopeful for the KUBECONFIG support in the next planned release.
from kube-no-trouble.
Hi @johnlane, new 0.4.0 release just went out, which includes support of KUBECONFIG
env variable. I wouldn't worry too much about different output compared to 0.2.0, there have been quite a few fixes and changes to sort out duplicate/false-positive findings and missing namespace in case of helm collector. Please give it a go with the latest 0.4.0 and if you still see something that doesn't look right let us know. Thanks 👍
from kube-no-trouble.
Related Issues (20)
- panic: interface conversion: interface {} is nil, not string HOT 3
- Multi Tenant Shared EKS cluster HOT 3
- Entries appear that are not in config HOT 5
- Multiple additional kinds of the same resource are not respected HOT 2
- Failure to retrieve AKS cluster resources - kubelogin not found HOT 1
- PodSecurityPolicy Deprecation Not Detected HOT 4
- Skip already removed APIs HOT 2
- Add FAQ explaining potential false positives HOT 7
- Depreciation api call triggered in the kubernetes migration notification window HOT 2
- New release HOT 3
- Missing kubectl.kubernetes.io/last-applied-configuration Annotation in Kubernetes Resources and Inclusion in kubectl Reports HOT 2
- WRN failed to discover supported resources for policy/v1beta1 HOT 3
- Feature request - validate helm charts HOT 2
- kubeconfig context feature does not work in 0.7.1 version HOT 1
- Autofix using a --fix or --autofix flag HOT 2
- Distinguish between deprecated / removed apis in CI mode error code HOT 2
- Kubent cause AWS EKS upgrade warning HOT 4
- Helm charts scanning for deprecated APIs HOT 2
- Missing kubernetes 1.28 deprecations HOT 3
- Unable to give multiple manifest files for scanning HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kube-no-trouble.