[jbosstools-issues] [JBoss JIRA] (JBIDE-24236) cdk3 oc command

Andre Dietisheim (JIRA) issues at jboss.org
Tue Apr 11 17:45:00 EDT 2017


    [ https://issues.jboss.org/browse/JBIDE-24236?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13392597#comment-13392597 ] 

Andre Dietisheim edited comment on JBIDE-24236 at 4/11/17 5:44 PM:
-------------------------------------------------------------------

Great idea, really. 
In the preferences, where one does set the location of the oc binary we look up the PATH if the location is not set. See here: https://github.com/jbosstools/jbosstools-openshift/blob/master/plugins/org.jboss.tools.openshift.ui/src/org/jboss/tools/openshift/internal/ui/preferences/OpenShiftPreferencePage.java#L114
As you pointed out we might have to store oc binaries per connection, but only if it turns out that oc is not backward compatible (would oc 3.4 work with CDK 2.3?). As far as I remember there were problems. Verifying this is for sure 1 of the first steps to take. If that's not true, or the vast exception, I'd tend to think that we can simply also look up the cache for minishift beside the PATH.
A simple warning for known compat issues in specific oc binaries could also help keeping this simple with a single oc location stored in preferences (see here where we warn that oc < 1.1.1 is not working for rsync: https://github.com/jbosstools/jbosstools-openshift/blob/master/plugins/org.jboss.tools.openshift.ui/src/org/jboss/tools/openshift/internal/ui/preferences/OpenShiftPreferencePage.java#L195)


was (Author: adietish):
Great idea, really. 
In the preferences, where one does set the location of the oc binary we look up into different default locations and the PATH. 
See here: https://github.com/jbosstools/jbosstools-openshift/blob/master/plugins/org.jboss.tools.openshift.ui/src/org/jboss/tools/openshift/internal/ui/preferences/OpenShiftPreferencePage.java#L114
One of the problems is that the copy of the oc binary only exists for CDK3, not for CDK2
Another one might be that the different CDKs require different oc binaries. As far as I remember there were problems in backwards compatibility (would oc 3.4 work with CDK 2.3?). Verifying this is for sure 1 of the first steps to take. If this is true we'd even have to change the preferences to use different oc binaries for different CDKs. If that's not true, or the vast exception, I'd tend to think that we can simply also look up the cache for minishift beside the path.

> cdk3 oc command
> ---------------
>
>                 Key: JBIDE-24236
>                 URL: https://issues.jboss.org/browse/JBIDE-24236
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: cdk, openshift
>            Reporter: Rob Stryker
>            Assignee: Rob Stryker
>
> After minishift setup-cdk,  the oc command is at    %USERPROFILE%\.minishift\cache\oc\v3.4.1.2
> Should our tools help streamline this process for users? I would suggest yes, but needs investigation **how** to do it. 
> Another question is, do we need different 'oc' command versions for each openshift connection? Should it really be a workplace setting? Or should it be per-connection? 



--
This message was sent by Atlassian JIRA
(v7.2.3#72005)


More information about the jbosstools-issues mailing list