Bug 1296184 - oc command is altering paths from relative to direct (after executing commands)
Summary: oc command is altering paths from relative to direct (after executing commands)
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 3.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
: ---
Assignee: Fabiano Franz
QA Contact: Xingxing Xia
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-01-06 14:35 UTC by Eric Rich
Modified: 2017-03-08 18:26 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-09-27 09:34:55 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1933 normal SHIPPED_LIVE Red Hat OpenShift Container Platform 3.3 Release Advisory 2016-09-27 13:24:36 UTC

Description Eric Rich 2016-01-06 14:35:06 UTC
Description of problem:

The OC command seems to alter file paths to certificates, from a relative path to a direct path (and vice versa) when commands are run. 

Version-Release number of selected component (if applicable): 3.0.1
How reproducible: 100%

Steps to Reproduce:

[root@workstation ~]# oc new-project test
Now using project "test" on server "https://master.example.com:8443".
[root@workstation ~]# oc delete project test
projects/test
[root@workstation ~]# oc logout
Logged "erich" out on "https://master.example.com:8443"
[root@workstation ~]# grep certificate-authority .kube/config
    certificate-authority: /home/student/Desktop/ca.crt

[root@workstation ~]# oc login -u erich -p redhat
Login successful.
...
[root@workstation ~]# oc delete project test2
Error from server: User "erich" cannot delete projects in project "test2"
[root@workstation ~]# oc delete project test2
Error from server: User "erich" cannot delete projects in project "test2"
[root@workstation ~]# oc logout
Logged "erich" out on "https://master.example.com:8443"
[root@workstation ~]# grep certificate-authority .kube/config
    certificate-authority: ../../home/student/Desktop/ca.crt

Actual results:

Path seems to change from direct path to a relative path and back for no reason (needed reason). 

    certificate-authority: /home/student/Desktop/ca.crt
    certificate-authority: ../../home/student/Desktop/ca.crt

Expected results:

This should be a "direct paht" or relative path (but the path should remain consist unless the use changes the path (via a command or config change). 

Additional info:

Comment 1 Fabiano Franz 2016-07-04 21:55:50 UTC
Fixed in master.

Comment 2 Eric Rich 2016-07-05 03:43:28 UTC
(In reply to Fabiano Franz from comment #1)
> Fixed in master.

Can you please link to commit or pr

Comment 3 Xingxing Xia 2016-07-07 06:02:44 UTC
Verified in oc v3.0.1.100, oc v3.1.1.6-35-g0742c54 and oc v3.3.0.2 per steps in comment 0. They all don't reproduce the issue. The actual result is always absolute path. @ Eric Rich, do you still reproduce it?

Comment 6 errata-xmlrpc 2016-09-27 09:34:55 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-2016:1933


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