openshift / jenkins-plugin

Apache License 2.0
81 stars 50 forks source link

Question about README #52

Closed xiuwang closed 8 years ago

xiuwang commented 8 years ago

@gabemontero I have a question in the comment about this commit https://github.com/openshift/jenkins-plugin/commit/895c47ba363b3524df70adba40f3b001daf46108

gabemontero commented 8 years ago

hey @xiuwang - responded in the commit as well, but I'll repeat here:

hey @xiuwang - perhaps I should change it to : "if a namespace is specified in the json/yaml provided for any of the resources, that namespace will take precedence over the namespace specified in the "The name of the project to create ..."

Does that make it more understandable?

wewang58 commented 8 years ago

@gabemontero In my remember, if we create resource(json is not include namespace , for example: https://raw.githubusercontent.com/openshift/origin/master/examples/hello-openshift/hello-pod.json) in test1 , the resource should be in test1, if we add namespace in json/yaml , I don't think it's convenient. my understand of "if a namespace is specified in the json/yaml provided for any of the resources, that namespace will take precedence over the namespace specified in the "The name of the project to create ..." is that a namespace is not specified in json, the resource is created in project which is setting in "The name of the project to create ..."

wewang58 commented 8 years ago

but now using hello-pod.json to create resources in test1, but actually created resouces in test which has jenkins

gabemontero commented 8 years ago

Hey @wewang58 - I realize that I should have provided some more information to you.

1) the README at http://github.com/openshift/jenkins-plugin reflects the functionality of the very latest code, which can be later than the version of the plugin installed in the openshift jenkins images for rhel (and occasionally for centos though usually that is up to date).

As such, the piece around the namespace used while creating resources is based off of this commit: https://github.com/openshift/jenkins-plugin/commit/895c47ba363b3524df70adba40f3b001daf46108

That change came between the 1.0.20 and 1.0.21 releases.

Do you know which release of the plugin you were running with? If you were not at v1.0.21 of the plugin, I'd like for you to retry with that version installed, and tell me the results.

If you want to get an officially released version of the plugin that has the fix associated with https://github.com/openshift/jenkins-plugin/commit/895c47ba363b3524df70adba40f3b001daf46108, I suggest you download the latest released version, install it into a running jenkins server, restart the jenkins server, and give it a try.

2) for documentation and code associated with the latest official release of the plugin, go to https://github.com/jenkinsci/openshift-pipeline-plugin

In the interim, I am going to open a documentation PR to add the clarification I previously posted in this issue. I'll tag you so you can provide feedback.

thanks, gabe

gabemontero commented 8 years ago

@wewang58 - hey, any chance you'll be able to get back to this next week (Aug 1 - Aug 5), using the latest version of the plugin (where if you are using the rhel image, you might have to download and install the latest plugin) ?

If not I'm going to close this, as the multiple namespace stuff is working for me.

I've merge the README update.

wewang58 commented 8 years ago

@gabemontero now tested plugin 1.0.21 ,when created resource in test1, pod is in test1 now ,thanks

gabemontero commented 8 years ago

Cool - thanks for confirming @wewang58