Bug 1264500 - cannot pass comma-delimted values with oc parameters
Summary: cannot pass comma-delimted values with oc parameters
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 3.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: ---
Assignee: Fabiano Franz
QA Contact: Wei Sun
URL:
Whiteboard:
Depends On:
Blocks: 1267746
TreeView+ depends on / blocked
 
Reported: 2015-09-18 15:28 UTC by Bill DeCoste
Modified: 2019-10-10 10:13 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-05-12 16:24:42 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2016:1064 0 normal SHIPPED_LIVE Important: Red Hat OpenShift Enterprise 3.2 security, bug fix, and enhancement update 2016-05-12 20:19:17 UTC

Description Bill DeCoste 2015-09-18 15:28:51 UTC
Description of problem:
I've been trying to figure out how to pass comma-delimited values using oc
parameters. For example (note MQ_PROTOCOL):

oc process -f amq/amq6-basic.json -v
APPLICATION_NAME=messaging,MQ_USERNAME=username,MQ_PASSWORD=password,MQ_PROTOCOL=stomp,amqp
| oc create -f -

The comma between 'stomp' and 'amqp' is always parsed as parameter delimiter
not a value delimiter no matter what combination of \ ^ " ' I use. Could you
point me to who I should talk to about the Go parser in oc?


Per Clayton:
We shouldn't have done -v like we did.  Please open a bug "process
must take multiple -v arguments" and we can fix it.

Version-Release number of selected component (if applicable):


How reproducible:
100%


Steps to Reproduce:
1. oc process -f amq/amq6-basic.json -v
APPLICATION_NAME=messaging,MQ_USERNAME=username,MQ_PASSWORD=password,MQ_PROTOCOL=stomp,amqp
| oc create -f -
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Clayton Coleman 2015-09-18 15:35:34 UTC
-v should not have been implemented with string splitting.  We have to accept multiple -v.

Because of backcompat, we need to introduce a new multiple value form, and we should probably accept argument key=value pairs like oc env

Comment 3 Fabiano Franz 2016-02-03 21:23:57 UTC
Fixed in https://github.com/openshift/origin/pull/7013

Comment 4 Wei Sun 2016-02-04 03:22:29 UTC
Will check this bug after the pr is merged

Comment 5 Wei Sun 2016-02-05 06:05:07 UTC
Checked this bug in devenv-rhel7_3335,it was fixed.After the pr is merged to ose puddle,I'll check again.

Result:
# oc process -f https://raw.githubusercontent.com/jboss-openshift/application-templates/master/amq/amq62-basic.json APPLICATION_NAME=messaging MQ_USERNAME=username MQ_PASSWORD=password,MQ_PROTOCOL=stomp,amqp | oc create -f -
service "messaging-amq-amqp" created
service "messaging-amq-mqtt" created
service "messaging-amq-stomp" created
service "messaging-amq-tcp" created
deploymentconfig "messaging-amq" created

Comment 6 Wei Sun 2016-02-14 09:18:01 UTC
The bug has been fixed on the latest puddle.

$ oc version
oc v3.1.1.901
kubernetes v1.2.0-origin

Comment 10 errata-xmlrpc 2016-05-12 16:24:42 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/RHSA-2016:1064


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