Bug 1322665 - Usage of some oc commands may be misleading due to 'options' is put after 'COMMAND' such as oc set probe, oc debug etc
Summary: Usage of some oc commands may be misleading due to 'options' is put after 'CO...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OKD
Classification: Red Hat
Component: oc
Version: 3.x
Hardware: Unspecified
OS: Unspecified
medium
low
Target Milestone: ---
: ---
Assignee: Fabiano Franz
QA Contact: Xingxing Xia
URL:
Whiteboard:
: 1330845 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-03-31 03:42 UTC by Peter Ruan
Modified: 2016-09-19 13:51 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-09-19 13:51:30 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Peter Ruan 2016-03-31 03:42:31 UTC
Description of problem:
  The double dash used by 'oc debug' get confused with user also specify a config location.


Version-Release number of selected component (if applicable):
oc v3.2.0.4
kubernetes v1.2.0-origin-41-g91d3e75

How reproducible:
always.

Steps to Reproduce:
1.  oc debug -f pod_simple.yaml -- /bin/env --config=/home/pruan/workdir/dhcp-16-139-pruan/ose_pruan1.kubeconfig
2.
3.

Actual results:
oc debug -f pod_simple.yaml -- /bin/env --config=/home/pruan/workdir/dhcp-16-139-pruan/ose_pruan1.kubeconfig

      error: unable to connect to a server to handle "pods": No configuration file found, please login or point to an existing file:
      
        1. Via the command-line flag --config
        2. Via the KUBECONFIG environment variable
        3. In your home directory as ~/.kube/config
      
      To view or setup config directly use the 'config' command.


Expected results:


Additional info:

Comment 1 Xingxing Xia 2016-06-07 06:28:48 UTC
Better to update usage info, like `oc exec -h` which differentiate between and order oc options and COMMAND args

Comment 2 Xingxing Xia 2016-06-07 06:29:57 UTC
*** Bug 1330845 has been marked as a duplicate of this bug. ***

Comment 3 Fabiano Franz 2016-07-04 21:35:30 UTC
Fixed in https://github.com/openshift/origin/pull/9693

Comment 4 Xingxing Xia 2016-07-05 08:58:56 UTC
Thanks. VERIFIED in oc v1.3.0-alpha.2-381-gd81b0cc. Now 'options' is put before 'COMMAND' in sub-command usage help info


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