Bug 1695225 - [rebase] UPSTREAM: 73469: Added windows executable extensions to Kubectl plugins
Summary: [rebase] UPSTREAM: 73469: Added windows executable extensions to Kubectl plugins
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: 4.1.0
Assignee: Maciej Szulik
QA Contact: zhou ying
URL:
Whiteboard:
: 1699705 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-02 16:58 UTC by David Eads
Modified: 2019-06-04 10:47 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: No Doc Update
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-06-04 10:46:54 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:0758 0 None None None 2019-06-04 10:47:00 UTC

Description David Eads 2019-04-02 16:58:12 UTC
confirm this made it into master

Comment 1 Maciej Szulik 2019-04-05 20:32:26 UTC
Fix in https://github.com/openshift/origin/pull/22498

Comment 2 zhou ying 2019-04-15 07:10:24 UTC
Verified with latest oc , this not fixed:
Client Version: version.Info{Major:"4", Minor:"1+", GitVersion:"v4.1.0", GitCommit:"eee567b9d", GitTreeState:"", BuildDate:"2019-04-14T17:00:04Z", GoVersion:"", Compiler:"", Platform:""}

C:\Users\oppenshift\Downloads> oc plugin list
The following compatible plugins are available:

C:\Program Files\Microsoft Windows Performance Toolkit\oc-far-foo.exe
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxia.cmd
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxiatest.bat
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxiaxshell.exe

error: unable to read directory "" in your PATH: open : The system cannot find the file specified.

C:\Users\oppenshift\Downloads>oc xxia
not supported by windows

Comment 3 Michal Fojtik 2019-04-15 09:39:09 UTC
*** Bug 1699705 has been marked as a duplicate of this bug. ***

Comment 4 Maciej Szulik 2019-04-16 08:53:41 UTC
> error: unable to read directory "" in your PATH: open : The system cannot find the file specified.

This looks like an error in the configuration. Not a plugin problem per se.


> C:\Users\oppenshift\Downloads>oc xxia
> not supported by windows

Similarly, the fact that windows cannot execute a specific binary is not a problem for oc.
Plugin mechanism is working as expected.

Based on the above I'm moving this back to QA.

Comment 5 zhou ying 2019-04-17 02:02:05 UTC
When I use the `path` command :

C:\Users\oppenshift>path
PATH=C:\Program Files (x86)\NetSarang\Xshell 6\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files\Microsoft Windows Performance Toolkit\;C:\WINDOWS\System32\OpenSSH\;C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps;


Seems no configuration error ?

Comment 6 Maciej Szulik 2019-04-17 12:56:52 UTC
It looks like the error reading directory is different on windows, I've fixed it in https://github.com/openshift/origin/pull/22590
I'm moving this back to POST and will move to qa once the PR merges.

Comment 7 zhou ying 2019-04-22 07:04:02 UTC
Confirmed with latest oc client, no error info:
C:\Users\oppenshift>oc version
Client Version: version.Info{Major:"4", Minor:"1+", GitVersion:"v4.1.0", GitCommit:"74c534b60", GitTreeState:"", BuildDate:"2019-04-21T21:13:18Z", GoVersion:"", Compiler:"", Platform:""}
Unable to connect to the server: dial tcp: lookup api.qe-xxia-0417-2.qe.devcluster.openshift.com: no such host

C:\Users\oppenshift>oc plugin list
The following compatible plugins are available:

C:\Program Files\Microsoft Windows Performance Toolkit\oc-far-foo.exe
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxia.cmd
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxiatest.bat
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxiaxshell.exe
Unable read directory "" from your PATH: open : The system cannot find the file specified.. Skipping...

Comment 8 zhou ying 2019-04-22 09:20:07 UTC
Hi Maciej:

    I've two questions about this issue:
    1) when I set PATH without the space , also see the info, I want to know why ? 

  C:\Users\oppenshift>path
PATH=C:\WINDOWS\System32\OpenSSH\;C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps;

C:\Users\oppenshift>oc plugin list
The following compatible plugins are available:

C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxia.cmd
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxiatest.bat
C:\Users\oppenshift\AppData\Local\Microsoft\WindowsApps\oc-xxiaxshell.exe
Unable read directory "" from your PATH: open : The system cannot find the file specified.. Skipping...


    2)I want to double confirm for windows cannot execute a specific binary:   "not supported by windows", is this by design ?

Comment 9 Maciej Szulik 2019-04-23 07:01:08 UTC
Yes the error is expected, in https://github.com/openshift/origin/pull/22590 we've decided to always show 
the information about problems but continue processing. This replaced previous error string matching 
solution which was working only on linux.

Comment 10 Maciej Szulik 2019-04-23 07:53:39 UTC
> 2)I want to double confirm for windows cannot execute a specific binary:   "not supported by windows", is this by design ?

Yes, that's an operating system limitation, we can't address that. I'm guessing this is version specific, and we don't want 
to go that granular with allowed extensions.

Comment 12 errata-xmlrpc 2019-06-04 10:46:54 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2019:0758


Note You need to log in before you can comment on or make changes to this bug.