Bug 2024212

Summary: no configuration has been provided, try setting KUBERNETES_MASTER environment variable
Product: OpenShift Container Platform Reporter: Derek Higgins <derekh>
Component: Test FrameworkAssignee: Derek Higgins <derekh>
Status: CLOSED WORKSFORME QA Contact:
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.10CC: pmuller, stbenjam
Target Milestone: ---   
Target Release: 4.10.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 2023631 Environment:
Last Closed: 2022-03-21 17:55:50 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 2023631, 2024656, 2027262    
Bug Blocks:    

Description Derek Higgins 2021-11-17 15:33:39 UTC
A case of this bug was fixed in #2023631, this bug covers a more general case 

While running the tests, they can sometimes read KUBECONFIG while another test is writing to it, resulting in a blank file being read and error messages similar to 

fail [github.com/openshift/origin/test/extended/util/client.go:524]: Nov 15 22:41:04.835: invalid configuration: no configuration has been provided, try setting KUBERNETES_MASTER environment variable

To protect tests from this in as much as possible we should arrange for each CLI object to read from KUBECONFIG only once to a temporary file and subsequent read will then come from this temp file reducing the likely hood of getting a bad read.

Comment 1 Petr Muller 2021-11-23 13:52:10 UTC
Reassigning to Test Framework who own the OCP testsuite

Comment 3 Stephen Benjamin 2022-03-21 17:55:50 UTC
I think this is fixed, as there's no recent instances of it.  https://search.ci.openshift.org/?search=invalid+configuration%3A+no+configuration+has+been+provided%2C+try+setting+KUBERNETES_MASTER&maxAge=168h&context=1&type=junit&name=&excludeName=&maxMatches=5&maxBytes=20971520&groupBy=job

I am going to close this bug and the linked PR.  If that's not correct, please re-open.